Can we use async calls in RestAPI qurries to run processes?
Hi
This is a follow up to issue #411 (closed)
Which determined that IBM Cloud side proxy timeout prevented Arc from executing processes that took longer than 60 sec.
IBM did not offer any solution to change the settings but they suggested the following and I would like you to comment on, and see if this can be incorporated in the mechanism that we use to trigger processes:
According to L3 best practice is to use async calls to execute a TI process via REST API, quote:
"There may be some timeouts that are configured on customer's infrastructure or on IBM's infrastructure (for example Apache web server).
What if the TI process runs for 30 min or 1 hour? increasing timeout is not the best approach.
For async request, they can indicate a query to be processed asynchronously by using the prefer: respond-async
header. The query results will be included in the _asyncs
collection.
The specification of the async requests could be found in the odata doc (search "async"):
http://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html
The server will respond immediately, with the location (in the header) of the response. Then they could query the location (e.g. /_async('xx')) to retrieve the response (to check the response code).
202 response code - job is still in progress
200 - it's completed."