Shutdown
This page describes the different ways to shutdown REST server gracefully. It also describes the behaviour of the REST server if the license server goes down.
Graceful Shutdown
A REST server can be shutdown using following options:
Using Control-C
System wide shutdown
Using REST Server shutdown end point
In all above cases, the REST server will check for any running comparisons before initiating the shutdown. REST Server will shut itself down after completing all the running comparisons. At same time, the REST server will not accept any new comparison.
REST Server shutdown end point
Simple shutdown call from postman:
Use the POST command with this string: http://0.0.0.0:8080/api/json/v1/shutdown
Response
{
"initiateTime": "2020-09-15T12:48:21.839+0000",
"runningComparisons": 0,
"info": "REST Server shut down initiated. It will be completed after finishing the running comparisons."
}
Shutdown due to license server
A license server can go down for several reasons like:
Intentional license server shutdown
License expiry
System shutdown
Power outage
The REST server is constantly checking for license server heartbeat and it will be lost if license server goes down. The REST Server will be try to reconnect to license server 2 times after some defined interval. The REST Server will initiate the graceful shutdown if it fails to reconnect.