Hi,
I have added UCSD (as a REST host with API access key) in vRealize orchestrator and is invoking a REST host command. The workflow runs successfully in vRO, but doesnot create a new service request (as it suppose to) in UCSD for new VM creation. The worksflow script is
var operationUrl = "/app/api/rest?formatType=json&opName=userAPISubmitServiceRequest&opData=%7Bparam0:'CentOS7',param1:'BSC&vDC',param2:1,param3:-1,param4:1,param5:'Provisioning%20VM%20from%20vRA'%7D"
var requestType = "POST"
System.log("Host: " + restHost + ", operation: " + operationUrl + ", Request Type: " + requestType);
var request = restHost.createRequest(requestType, operationUrl);
request.setHeader("X-Cloupia-Request-Key","XXXXXX");
System.log("request: " + request.fullUrl);
var response = request.execute();
System.log("response: " + response.contentAsString);
result = new Properties();
result.put("statusCode", response.statusCode);
result.put("contentLength", response.contentLength);
result.put("headers", response.getAllHeaders());
result.put("contentAsString", response.contentAsString);
Here are the orchestrator workflow logs
[2018-06-22 09:22:22.673] [I] Host: DynamicWrapper (Instance) : [RESTHost]-[class com.vmware.o11n.plugin.rest.RESTHost] -- VALUE : RESTHost [name=UCSDirector, id=9b1024f4-0e50-4e01-bb73-98bad7be38dc, url=https://bscccucsd.sentinelbsc.com, connectionTimeout=30, operationTimeout=1200, hostVerification=false, proxyHost=, proxyPort=0, schemaRepo=com.vmware.o11n.plugin.rest.schema.SchemaRespository@18152643, resourceId=null, privateKeyId=null], operation: /app/api/rest?formatType=json&opName=userAPISubmitServiceRequest&opData=%7Bparam0:'CentOS7',param1:'BSC&vDC',param2:1,param3:-1,param4:1%7D, Request Type: undefined
[2018-06-22 09:22:22.675] [I] request: https://bscccucsd.sentinelbsc.com/app/api/rest?formatType=json&opName=userAPISubmitServiceRequest&opData=%7Bparam0:'CentOS7',param1:'BSC&vDC',param2:1,param3:-1,param4:1%7D
[2018-06-22 09:27:22.773] [I] response: { "serviceResponse":null, "serviceError":"SERVICE_CALL_EXCEPTION: Requested timeout", "serviceName":"InfraMgr", "opName":"userAPISubmitServiceRequest" }..
Any thoughts?
Thanks