Tasks in the Spatial Analysis service run asynchronously, meaning that you submit a request (or job) and then poll the service for status. When you submit a request, the Spatial Analysis service returns a unique job ID for the transaction. You can use the job ID to periodically check the status of the job and messages.
Syntax:
http://<analysis url>/arcgis/rest/services/tasks/GPServer/<task name>/jobs/<jobId>
The job will start with a status of esri
. When the job has successfully completed, the job status will change to esri
and the results
resource will be populated. You can append the param
value from the results
resource to the request with the job ID to retrieve the results of the task.
jobStatus values
The job
property can have the following values:
esri
J o b Submitted esri
J o b Waiting esri
J o b Executing esri
J o b Succeeded esri
J o b Failed esri
J o b Timed Out esri
J o b Cancelling esri
J o b Cancelled