jclouds-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alka Beniwal <beniwala...@gmail.com>
Subject Is there anyone for whom,NovaApi extension SimpleTenantUsageExtension is working????
Date Thu, 04 Dec 2014 10:19:10 GMT
Hi,
I am developing a code to retrieve total usage of resources in
OpenStack.For that i am using NovaApi extension SimpleTenantUsageExtension.

*Code*-
SimpleTenantUsageApi
simpleTenantUsageApi=novaApi.getSimpleTenantUsageExtensionForZone(zone).get();
    SimpleTenantUsage
simpleTenantUsage=simpleTenantUsageApi.get("894f600a8bf0tyty37895d");
Double totalLocalGbUsage=simpleTenantUsage.getTotalLocalGbUsage();
Double totalMemoryMbUsage=simpleTenantUsage.getTotalMemoryMbUsage();
Double totalVcpusUsage=simpleTenantUsage.getTotalVcpusUsage();
where 894f600a8bf0tyty37895d is Admin Project id.



*Error-*
org.jclouds.http.HttpResponseException: command: GET
http://controller:8774/v2/ 894f600a8bf0tyty37895d/os-simple-tenant-usage
HTTP/1.1 failed with response: HTTP/1.1 400 Bad Request; content:
[{"badRequest": {"message": "The server could not comply with the request
since it is either malformed or otherwise incorrect.", "code": 400}}]


I am getting same error by using curl and in browser also by using URI
http://10.236.12.33:8774/v2/894f600a8bf0tyty37895d/os-simple-tenant-usage*
-*H "User-Agent: python-keystoneclient" -H
"X-Auth-Token:MIINvgYJKoZIhvcNAQcCoIINrzCCDasCAQExCTAHBgUrD”





Any help is appreciated.




--
Thanks,
Regards,
AB

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message