NodeMetadata is not recording the group and name.
It is not just and issue of NodeMetadata not displaying properly,
The ComputeService.listNodesDetailsMatching with filter inGroup() does
not find the desired group, e.g.
iNodeMetadatas = filter(mCompute.listNodesDetailsMatching(all()),
and(inGroup(pGroupName), not(TERMINATED));
The iNodeMetadatas is empty.
This is the code segment to create a node and print out NodeMetadata.
iNodeMetadata =
getOnlyElement(mCompute.createNodesInGroup(System.getProperty("
user.name"),
1, template));
System.out.printf("VMInstance group=%s iNodeMetadata=%s%n",
iNodeMetadata.getGroup(),iNodeMetadata);
Results from printf for windows instance:
VMInstance group=null iNodeMetadata=[id=us-east-1/i-4b6df22e,
providerId=i-4b6df22e, group=null, name=null, location=[id=us-east-1c,
scope=ZONE, description=us-east-1c, parent=us-east-1, iso3166Codes=[US-
VA], metadata={}], uri=null, imageId=us-east-1/ami-133fee7a,
os=[name=null, family=windows, version=, arch=hvm, is64Bit=false,
description=300629125119/Windows-2003R-i386-Base-cygwin-
ts-2012-02-01], state=RUNNING, loginPort=22,
hostname=ip-10-245-205-106, privateAddresses=[10.245.205.106],
publicAddresses=[23.20.9.160], hardware=[id=t1.micro,
providerId=t1.micro, name=null, processors=[[cores=1.0, speed=1.0]],
ram=630, volumes=[[id=vol-51bb763d, type=SAN, size=null, device=/dev/
sda1, durable=true, isBootDevice=true]],
supportsImage=And(requiresRootDeviceType(ebs),Or(isWindows(),requiresVirtualizationType(paravirtual)),ALWAYS_TRUE,ALWAYS_TRUE),
tags=[]], loginUser=root, userMetadata={}, tags=[]]
Results from printf for ubuntu instance:
VMInstance group=null iNodeMetadata=[id=us-east-1/i-3722bd52,
providerId=i-3722bd52, group=null, name=null, location=[id=us-east-1b,
scope=ZONE, description=us-east-1b, parent=us-east-1, iso3166Codes=[US-
VA], metadata={}], uri=null, imageId=us-east-1/ami-b94f85d0,
os=[name=null, family=ubuntu, version=, arch=paravirtual,
is64Bit=false, description=300629125119/ubuntu-aeskulap],
state=RUNNING, loginPort=22, hostname=ip-10-72-81-36,
privateAddresses=[10.72.81.36], publicAddresses=[50.16.31.46],
hardware=[id=t1.micro, providerId=t1.micro, name=null,
processors=[[cores=1.0, speed=1.0]], ram=630,
volumes=[[id=vol-8fd21fe3, type=SAN, size=null, device=/dev/sda1,
durable=true, isBootDevice=true]],
supportsImage=And(requiresRootDeviceType(ebs),Or(isWindows(),requiresVirtualizationType(paravirtual)),ALWAYS_TRUE,ALWAYS_TRUE),
tags=[]], loginUser=root, userMetadata={}, tags=[]]
In the EC2, the console displays the group is being assigned to the VM
instance name plus a unique prefix.
It also shows that the name is added as user supplied Name tag.