Control Task Processing
Many Oracle Health Insurance applications make use of a queue based task distribution and processing mechanism. If task processing is:
-
started then the Oracle Health Insurance application picks tasks from the queue and processes these;
-
stopped then the Oracle Health Insurance application does not pick tasks from the queue.
Under normal conditions task processing is started. It can (temporarily) be stopped for importing a configuration set using the Configuration Migration Tool (CMT). When the configuration set is imported task processing can be started again so that tasks are processed with updated configuration data.
The "taskprocessing" resource can be used to:
-
determine the status of the task processing mechanism;
-
(temporarily) stop task processing;
-
start task processing (when it was stopped).
Determine Task Processing Status
The resource also allows inquiry about the status by executing:
GET http://[hostName]:[portNumber]/[api-context-root]/taskprocessing
which returns a response like the following when task processing is started:
{
"status": "started",
"statistics": {
"waiting": <number>
"ready": <number>
"expired": <number>
}
"links": {
"defaultLink": [
{
"rel": "self",
"href": "http://[hostName]:[portNumber]/[api-context-root]/taskprocessing"
},
{
"rel": "taskprocessing:control",
"href": "http://[hostName]:[portNumber]/[api-context-root]/taskprocessing?action=stop",
"httpMethod": "POST"
}
]
}
}
The client can determine the options based on the links, for example, stop task processing using the "taskprocessing:control" option.
The statistics part is useful for monitoring the queue. The "waiting", "ready" and "expired" fields originate from the V$AQ database view.
For convenience, the meaning of these 3 properties is repeated here:
-
"waiting": Number of messages in the queue in the state 'WAITING'. Waiting messages are queued with a delay, and the delay has not gone by yet.
-
"ready": Number of messages in the queue in the state 'READY'. Ready messages are available for dequeue by the Oracle Health Insurance applications.
-
"expired": Number of messages in the queue in the state 'EXPIRED'. Expired messages are messages that are not dequeued within the expiration time.