[ https://issues.apache.org/jira/browse/CLOUDSTACK-8857?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15879983#comment-15879983 ]
ASF subversion and git services commented on CLOUDSTACK-8857: ------------------------------------------------------------- Commit cd68e99148ac9ed96a8d1906b206cb5c5bcee11b in cloudstack's branch refs/heads/master from [~rajanik] [ https://git-wip-us.apache.org/repos/asf?p=cloudstack.git;h=cd68e99 ] Merge pull request #838 from bvbharatk/CLOUDSTACK-8857 CLOUDSTACK-8857 listProjects doesn't return tags vmstopped or vmrunning when their value is zero listProjects doesn't return tags vmstopped or vmrunning when their value is zero added the the appropriate tags to response. tested this manually by creating projects, launching vms from project accounts and then listing the projects. * pr/838: CLOUDSTACK-8857 listProjects doesn't return tags vmstopped or vmrunning when their value is zero Signed-off-by: Rajani Karuturi <rajani.karut...@accelerite.com> > 'listProjects' doesn't return tags 'vmstopped' or 'vmrunning' when their > value is zero > --------------------------------------------------------------------------------------- > > Key: CLOUDSTACK-8857 > URL: https://issues.apache.org/jira/browse/CLOUDSTACK-8857 > Project: CloudStack > Issue Type: Bug > Security Level: Public(Anyone can view this level - this is the > default.) > Reporter: Bharat Kumar > Assignee: Bharat Kumar > > 'listProjects' doesn't return tags 'vmstopped' or 'vmrunning' when their > value is zero. > Eg: > API result when 1 vm is stopped and 0 vms are running: > curl -s > 'http://127.0.0.1:8096/api?command=listProjects&account=admin&domainid=10513804-76ec-11e4-924f-065db2000097' > 2>/dev/null | xmllint --format - -o > <?xml version="1.0" encoding="UTF-8"?> > <listprojectsresponse cloud-stack-version="4.3.0.1"> > <count>1</count> > <project> > <id>a811d7e1-3ec7-4dda-92c4-4792200f38cf</id> > <name>abc</name> > <displaytext>abc</displaytext> > <domainid>10513804-76ec-11e4-924f-065db2000097</domainid> > <domain>ROOT</domain> > <account>admin</account> > <state>Active</state> > <networklimit>20</networklimit> > <networktotal>1</networktotal> > <networkavailable>19</networkavailable> > <vpclimit>20</vpclimit> > <vpctotal>0</vpctotal> > <vpcavailable>20</vpcavailable> > <cpulimit>40</cpulimit> > <cputotal>1</cputotal> > <cpuavailable>39</cpuavailable> > <memorylimit>40960</memorylimit> > <memorytotal>512</memorytotal> > <memoryavailable>40448</memoryavailable> > <primarystoragelimit>200</primarystoragelimit> > <primarystoragetotal>2</primarystoragetotal> > <primarystorageavailable>198</primarystorageavailable> > <secondarystoragelimit>400</secondarystoragelimit> > <secondarystoragetotal>0</secondarystoragetotal> > <secondarystorageavailable>400</secondarystorageavailable> > <vmlimit>20</vmlimit> > <vmtotal>1</vmtotal> > <vmavailable>19</vmavailable> > <iplimit>20</iplimit> > <iptotal>1</iptotal> > <ipavailable>4</ipavailable> > <volumelimit>20</volumelimit> > <volumetotal>1</volumetotal> > <volumeavailable>19</volumeavailable> > <snapshotlimit>20</snapshotlimit> > <snapshottotal>0</snapshottotal> > <snapshotavailable>20</snapshotavailable> > <templatelimit>20</templatelimit> > <templatetotal>1</templatetotal> > <templateavailable>19</templateavailable> > <vmstopped>1</vmstopped> > </project> > </listprojectsresponse> > The above response should have a tag <vmrunning>0</vmrunning>, which is > missing, similar when the zero vms are stopped, vmstopped would be missing. > When there are no VMs in the project neither of these tags are in the > response. -- This message was sent by Atlassian JIRA (v6.3.15#6346)