Responding to Callbacks
{ "computeJobId": "my-job" "messageType": "APP_MESSAGE" "messagePayload": { "appMessageId": "uuid" "appMessageType": "BARLOG" "appMessageFile": "url to download from (INTSOL only)" "appMessage": { "problemName": "problem-name" "attributes" : { "att1Name" : { "key" 1234, "name": "att1Name" "value": "value" } } } } }
Each callback message includes the list of all solver attributes with their current values. The INTSOL callback includes a URL to request the current solution for the appMessageFile property.
A callback must be acknowledged. If the server does not receive an acknowledgment within 60 seconds then the job is terminated and marked as failed. This setting is configurable, for more see the folllowing section, Editing the Callback acknowledgment timeout.
To acknowledge a callback and continue, send the message below. The response must include the appMessageId value of the message it is responding to. The response can also set solver controls to new values.{ "computeJobId": "my-job" "messageType": APP_MESSAGE_RESPONSE "messagePayload": { "appMessageId": "id_of_the_received_message", "appMessage": { "interruptSolve": false, "controls": { "key": "newvalue" } } } }
{ "computeJobId": "my-job" "messageType": "APP_MESSAGE_RESPONSE", "messagePayload": { "appMessageId": "id_of_the_received_message", "appMessage": { "interruptSolve": true } } }
Editing the Callback acknowledgment timeout
- Navigate to the worker installation directory. These instructions use the term <INSTALLDATADIR> to describe the path to your installation directory. This path will normally be C:\ProgramData\FICO\Xpress Insight 5\Worker\ unless otherwise set by your IT department.
- Use a suitable text editor to open the all.properties file in the <INSTALLDATADIR>/config directory.
- Locate the entry insight.worker.system.websocket.app-message-timeout. Edit the associated value.
- Save and close the file, then reboot the worker.
© 2001-2020 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.