IMS recovery

After a system failure, IMS recovers following a restart from the last checkpoint it took.

This means that, if the failure occurs when IMS has committed a message to the input queue then, on restart, IMS requeues that message and schedules a transaction to process it. Similarly, IMS will requeue all output messages that it has committed to its output queues and not successfully sent.

When IMS fails, all sessions between FEPI and IMS are ended. This is reported to the FEPI application as a command error (‘session lost’). A FEPI application should check this so that it can tidy up before ending and take the appropriate action (such as informing the operator).

FEPI attempts to regain lost connections and, therefore, when IMS restarts, any previously acquired connections are reestablished. If IMS has committed an input or output message, eventually there is going to be an output message to send. With the connection reacquired, IMS attempts to recover its position and ultimately to send any queued output messages to the FEPI node that carried the original FEPI conversation. The process of recovery in this situation is different for each of the two modes:
  • SLU P recovery When IMS tries to recover SLU P connections, it uses ‘set and test sequence numbers’ (STSN) in an attempt to resynchronize failed conversations. The STSN flow from IMS carries its version of the sequence numbers for the node being resynchronized. If there is an STSN handler specified, it is started. If not, FEPI responds POSITIVE, which effectively tells IMS that FEPI is satisfied with the sequence numbers sent. On receiving this, IMS sends all messages queued for the node. FEPI receives the messages, discards them and responds to IMS, completing the resynchronization.
  • SLU2 recovery The queued message is sent by IMS until there is a request from a front-end application, that application will receive the message as unexpected data interleaved with the data that it expects to receive. This problem can be handled in either of two ways:
    1. By the application issuing a FEPI RECEIVE, with TIMEOUT, before starting its intended task or by dequeuing all output messages using CLEAR and PA1.
    2. By the begin-session handler.

This situation becomes more complex if the back-end transaction is IMS conversational, because the front-end transaction has no way of knowing this, and the IMS conversation will still be active in the back-end system awaiting input.

The potential therefore exists for a front-end FEPI application to allocate a FEPI conversation on a node where an IMS conversation still exists on the back-end system. Any data flowing on this FEPI conversation is viewed by the front-end application as an exchange with a new back-end transaction, but it is viewed by IMS as the next input message to the existing conversation. To prevent this situation occurring, you can use the begin-session handler to issue the IMS /EXIT command, which has the effect of ending an active IMS conversation.

Where the possibility exists of a number of nodes with active IMS conversations following a restart, it is possible to use FEPI to obtain a connection to IMS and control the clean up operation, from a single point. You do this by issuing, again from the appropriate handler:
  • An IMS /DISPLAY command to display all active conversations
  • The IMS /EXIT command to end all those attached to FEPI nodes.

In the event of a failure that unbinds all the FEPI connections to IMS, the recovery procedure is identical to that described here.



dfhp7c00190.html | Timestamp icon Last updated: Monday, 5 June 2017