Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • UserVm - virtual machine,

  • Template - virtual machine image,

  • ISO - ISO image,

  • Volume - virtual machine block device,

  • Snapshot - virtual machine volume snapshot,

  • Network - network where address ranges and other information specified,

  • LoadBalancer - load ballancer appliance,

  • PortForwardingRule,

  • FirewallRule,

  • SecurityGroup - elementary firewall for basic zone and for kvm-advanced zone,

  • SecurityGroupRule - certain traffic permit rule in SG,

  • PublicIpAddress,

  • Project - logical entity which organizes VMs and accounts into collaboration,

  • Vpc - virtual private cluster,

  • NetworkACL,

  • StaticRoute,

  • VMSnapshot - virtual machine (state, RAM, volumes) snapshot,

  • User - user, who accesses CloudStack,

  • Account - account which organizes users and manages owns cloud resources (CLOUDSTACK-10170, possibly 4.1112).

DB Changes:

All tags will be stored in `cloud`.`resource_tags` table. The table fields:

...

In this case we'll return all the volumes having tag region=canada OR tag city=Toronto (the same way Amazon does)

Implementation Details

 

details, getting started notes

All In case of the document is outdated, supported tags can be found in source file ResourceTag.java (master branch link): 

Code Block
languagejava
public enum ResourceObjectType {
   UserVm(true, true),
   Template(true, true),
   ISO(true, false),
   Volume(true, true),
   Snapshot(true, false),
   ...

...

Only items with first argument = "true" support tags, e.g. Zone: 

Code Block
languagejava
Zone(false, true)

 

doesn't support resource tags. If a developer wishes to add new tag next actions should be maintained:

  1. change api/src/com/cloud/server/ResourceTag.java (add new enum item);
  2. change server/src/com/cloud/tags/TaggedResourceManagerImpl.java (modify the code if necessary);
  3. modify integration tests for tags: test/integration/component/test_tags.py and add required tests for new resource type.

Limitations:

  • No tags for remote access VPN as this object doesn't have an ID.