VMware {code} Community
udaraliyanage
Contributor
Contributor

METHOD_NOT_ALLOWED

Hi,

I am using Stratogen as the IAAS provider.

I get the following error when I am going to build the compute service.

<< "<Error xmlns="http://www.vmware.com/vcloud/v1.5"

minorErrorCode="METHOD_NOT_

ALLOWED" message="HTTP method not allowed"
majorErrorCode="405" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.vmware.com/vcloud/v1.5
http://mycloud.stratogen.sg/api/v1.5/schema/master.xsd"></Error>[\n]"
2013-08-08 12:39:09,245 ERROR AllCatalogsInOrg [user thread 3]
catalogs in udara, completed: 0/2, errors: 1, rate: 245ms/op
org.jclouds.vcloud.VCloudResponseException: request GET
https://mycloud.stratogen.sg/api/admin/org/54aa217b-7a6b-4330-9016-7303a3d7562b/catalogsHTTP/1.1
failed with code 405, error: [majorErrorCode=405, message=HTTP
method not allowed, minorErrorCode=METHOD_NOT_ALLOWED, stackTrace=null,
vendorSpecificErrorCode=null]
     at
org.jclouds.vcloud.handlers.ParseVCloudErrorFromHttpResponse.handleError(ParseVCloudErrorFromHttpResponse.java:74)

From the error what I understood is GET request is not allowed here. What is wrong I have done and how to solve it?

Tags (2)
Reply
0 Kudos
1 Reply
nirvy
Commander
Commander

According to the API you can only POST to /api/admin/org/{id}/catalogs (ie to create new),  you can't use GET (see: http://pubs.vmware.com/vcd-51/index.jsp?topic=%2Fcom.vmware.vcloud.api.reference.doc_51%2Fdoc%2Foper...http://pubs.vmware.com/vcd-51/index.jsp?topic=%2Fcom.vmware.vcloud.api.reference.doc_51%2Fdoc%2Foper...).  If you are trying to get the organisations list of catalogs you need to issue a GET request for the organisation and then look at the down links returned that have a type of application/vnd.vmware.vcloud.catalog+xml, each one will have an href that will look like: https://cloud-url/api/catalog/{id}

Reply
0 Kudos