Details
-
Feature
-
Status: Released (View Workflow)
-
Minor
-
Resolution: Fixed
-
None
-
None
Description
Current Situation
The web services ./orders/add and ./jobs/start return just an "ok" if all jobs or orders started successfully or return a list of errors like this:
with HTTP 200
{ "deliveryDate": "...", "surveyDate": "...", "ok": true }
with HTTP 419
{ "deliveryDate": "...", "errors": [ { "surveyDate": "...", "path": "/path/to/jobChain1", "code": "JOC-419", "message": "/path/to/jobChain1 doesn't exist" } ] }
Desired Behavior
- The web service ./orders/add provides the Order Ids inside an array of orders, this array contains only successful order starts.
with HTTP 200
{ "deliveryDate": "...", "ok": true, "orders" : [ { "surveyDate": "...", "jobChain": "/path/to/jobChain1", "orderId": "42" }, { "surveyDate": "...", "jobChain": "/path/to/jobChain2", "orderId": "43" } ] }
with HTTP 419{ "deliveryDate": "...", "errors": [ { "surveyDate": "...", "path": "/path/to/jobChain1", "code": "JOC-419", "message": "/path/to/jobChain1 doesn't exist" } ], "orders" : [ { "surveyDate": "...", "jobChain": "/path/to/jobChain2", "orderId": "43" } ] }
- The web service ./jobs/start provides the Task Ids inside an array of tasks, this array contains only successful job starts.
with HTTP 200
{ "deliveryDate": "...", "ok": true, "tasks" : [ { "surveyDate": "...", "job": "/path/to/job1", "taskId": "42" }, { "surveyDate": "...", "job": "/path/to/job2", "taskId": "43" } ] }
with HTTP 419{ "deliveryDate": "...", "errors": [ { "surveyDate": "...", "path": "/path/to/job1", "code": "JOC-419", "message": "/path/to/job1 doesn't exist" } ] "tasks" : [ { "surveyDate": "...", "job": "/path/to/job2", "taskId": "43" } ] }