Hi,
I' m working on an extension service for vCloud. I call an URL via a POST request and then orchestrator run a workflow, this workflow send results via amqp to my vCloud.
This solution works great ! But when my workflow is running more than 10 seconds, vCloud api return this error : GATEWAY_TIMEOUT failed to respond in the specified timeout (10 SECONDS).
So my idea to avoid this problem is to create a task in vCloud when the workflow is running and return to the api an url which allows to consult the workflows state (running, completed, ...)
Do you think there is a way to do this ?
Thanks for your help !
Have you first ran the workflow to create the Workflow run service, then the one to create the custom service, then the one to add an operation to this custom service ?
If you get https://IP/api/workflows/id_workflow/executions/
Do you see the execution ID you are looking for ?
In the inventory / REST do you see the vCO host with its REST operations ?
Christophe.
It does so because you did not reply back in time.
If you look at the document tab there is a full implementation of this called "vCloud Service Builder" I have created.
You should definitely have a look at the included presentation. It explains how it works and all the features.
The way I decided to implement the reply is to return the workflow token as soon as I get it and set the location header to its URL in a similar way the vCO REST API is doing.
Christophe.
Yes I'm not replying in time, because my workflow is running more than 10 seconds.
Are you talking about his documentation : http://communities.vmware.com/docs/DOC-21726
Thanks for your reply !
Yes, check the linked online presentation for more details and get the package to check how this is implemented.
Thanks for your solution, That's a very nice work !!!
So I managed to make it work on my workflow. It runs and I received via amqp a url to manage workflow execution :
But when i make a GET on this Location, i have this kind of error :
HTTP/1.1 404 Not Found
Date: Wed, 10 Apr 2013 14:38:32 GMT
Host: IP
x-vcloud-authorization: token
User-Agent: curl/7.27.0
Accept: application/*+xml;version=1.5
Content-Length: 1003
<html><head><title>vCloud Director vCenter Orchestrator Service 0.1 - Error report</title><style><!--H1 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;} H3 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;} BODY {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} B {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} P {font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A {color : black;}A.name {color : black;}HR {color : #525D76;}--></style> </head><body><h1>HTTP Status 404 - </h1><HR size="1" noshade="noshade"><p><b>type</b> Status report</p><p><b>message</b> <u></u></p><p><b>description</b> <u>The requested method is not available.</u></p><HR size="1" noshade="noshade"><h3>vCloud Director vCenter Orchestrator Service 0.1</h3></body></html>
Have you got any idea why ?
PS : My workflow is running without error.
Have you first ran the workflow to create the Workflow run service, then the one to create the custom service, then the one to add an operation to this custom service ?
If you get https://IP/api/workflows/id_workflow/executions/
Do you see the execution ID you are looking for ?
In the inventory / REST do you see the vCO host with its REST operations ?
Christophe.
Have you first ran the workflow to create the Workflow run service, then the one to create the custom service, then the one to add an operation to this custom service ?
=> Yes I followed this order ! And every of these operations are successful
If you get https://IP/api/workflows/id_workflow/executions/
Do you see the execution ID you are looking for ?
=> If I get this URL, I also have a 404 error !
In the inventory / REST do you see the vCO host with its REST operations ?
=> Yes I see severals operations in the vCO host :
Get a workflow run event logs, Get an user interaction, get a workflow run state, ....
THanks for your help !
It seems that it is the mapping between orchestrator and vCloud that do not work.
I can access to all workflow executions via orchestrator IP but not via vCloud IP !!
I could reproduce your issue:
To fix it I had to GET
https://vcdServer/api/workflows/workflowID/executions/executionId
No trailing /
Please test this.
I have updated the package so the workflow service accept as well URLs finishing with /
Nice, I will test it as soon as possible.
For now I made my on map rules and workflow listener and it works.
Thanks a lot for your help !!
Regards