You can use the state diagrams to construct valid command sequences. Each diagram relates to one specific state and shows the commands that you might issue, and the tests to make, after you issue the command.
When a diagram shows more than one test, make them in the order indicated. The combination of the command issued and a particular positive test result leads to a new resultant state, shown in the final column.
The state diagrams shows tests that are significant to the state of the conversation. For other conditions that can occur, for example, INVREQ or NOTALLOC, make tests in the normal way.
Commands you can issue | What to test | New state |
---|---|---|
ALLOCATE [NOQUEUE] * | SYSIDERR | 1 |
Ditto | SYSBUSY * | 1 |
Ditto | Otherwise (obtain session name from EIBRSRCE) | 2 |
If you want your program to wait until a session is available, omit the NOQUEUE option of the ALLOCATE command and do not code a HANDLE command for the SYSBUSY condition.
If you want control to be returned to your program if a session is not immediately available, either specify NOQUEUE on the ALLOCATE command and test EIBRCODE for SYSBUSY (X'D3'), or code a HANDLE CONDITION SYSBUSY command.
Commands you can issue * | What to test | New state |
---|---|---|
SEND | 2 | |
SEND INVITE | — | 3 or 4 |
SEND LAST | — | 6 |
CONVERSE
|
Go to the STATE 4 table and make the tests shown for the RECEIVE command. | — |
RECEIVE | Go to the STATE 4 table and make the tests shown for the RECEIVE command. | — |
SYNCPOINT | (Transaction abends if SYNCPOINT fails.) | 2 |
FREE
|
— | 1 |
For the front-end transaction, the first command used after the session has been allocated must be a SEND command or CONVERSE command that initiates the back-end transaction in one of the ways described under Attaching the remote transaction.
Commands you can issue | What to test | New state |
---|---|---|
SYNCPOINT | (Transaction abends if SYNCPOINT fails.) | 4 |
Commands you can issue | What to test | New state |
---|---|---|
RECEIVE [NOTRUNCATE] * | EIBCOMPL * | — |
Ditto | EIBSYNC | 5 |
Ditto | EIBFREE | 7 |
Ditto | EIBRECV | 4 |
Ditto | Otherwise | 2 |
If NOTRUNCATE is specified, a zero value in EIBCOMPL indicates that the data passed to the application by CICS is incomplete (because, for example, the data area specified in the RECEIVE command is too small). CICS saves the remaining data for retrieval by later RECEIVE NOTRUNCATE commands. EIBCOMPL is set when the last part of the data is passed back. If the NOTRUNCATE option is not specified, over-length data is indicated by the LENGERR condition, and the remaining data is discarded by CICS.
Commands you can issue | What to test | New state |
---|---|---|
SYNCPOINT | EIBFREE (saved value) | 7 |
Ditto | EIBRECV (saved value) | 4 |
Ditto | Otherwise | 2 |
Commands you can issue | What to test | New state |
---|---|---|
SYNCPOINT | — | 7 |
FREE | — | 1 |
Commands you can issue | What to test | New state |
---|---|---|
FREE | — | 1 |