Jump to: navigation, search

Handle Application "Graceful Stop" with the LCA Protocol

Graceful stop is operation that allow application to complete current request handling before actual stop in case when such handling can require significant (time greater than application stop timeout) time.

Two new states are related to this command:

  • SUSPENDING – This state means that an application has understood the command from LCA, so that the application does NOT accept new requests (unless specified by Management Layer) and will complete current requests. This status should be reported by an application as the result of Suspend command from LCA. If the application does no support graceful stop then it can just ignore the Suspend command; no state changes should be reported in this case.
  • SUSPENDED – This state means that an application has completed handling current requests and can be stopped without any impact to its client.

For applications which DO support graceful stop, the scenario is as follows:

  1. SCI issues command "Stop application graceful"
  2. SCS receives command, sets up a suspended state timer and sends the Suspend application command to LCA
  3. LCA receives Suspend command and resends it to application (application receives EventSuspendApplication)
  4. Since the application supports this feature, it reports SUSPENDING state with RequestUpdateStatus and start behave accordingly
  5. SCS receives a status update through LCA and cancels the timer set at point (2).
  6. From this point, the application has unlimited time to complete handling requests (of course, it can also be stopped by usual stop command)
  7. When the application completes handling requests, it reports the status SUSPENDED (with RequestUpdateStatus)
  8. SCS receive the status update through LCA and stops the application with the usual stop command (EventChangeExecutionMode)

For applications which do NOT support graceful stop, the scenario is as follows:

  1. SCI issues the command: "Stop application graceful"
  2. SCS receives the command, sets up a suspended state timer and sends the Suspend application command to LCA
  3. LCA receives Suspend command and resends it to application
  4. Since the application does not support this feature, the Suspend command is ignored
  5. Suspended state timer set at point (2) expires in SCS. SCS determines that the application does not support Graceful stop.
  6. SCS issues an ordinary stop command to application (EventChangeExecutionMode).

Please also note that message between SCI-SCS and SCS-LCA are not same.

If your application should support graceful stop please check:

  • If application receives Suspend command from LCA.
  • If application correctly report SUSPENDING/SUSPENDED states.
  • If application can be stopped by usual stop command.

If your application should NOT support graceful stop please check:

  • If application can be stopped by usual stop command (in this case Graceful stop is equal to usual Stop command with some delay)
Tip
This feature is new for 8.0 Genesys Management Framework, so, all the involved components (SCI, SCS, LCA) should be 8.0+ versions (checked with 8.0.3x).

Feedback

Comment on this article:

blog comments powered by Disqus
This page was last modified on 20 June 2017, at 23:57.