Previous Page Contents Page Next Page

3.6 RUI_REINIT

The RUI_REINIT verb re-establishes the SSCP-LU session after a session failure. It is intended for use by an application that was using an LU from a pool, and needs to ensure that it accesses the same LU in order to continue processing. (Normally, an application recovers from a session failure by issuing RUI_TERM followed by a second RUI_INIT; however, if the application was using an LU from a pool, the second RUI_INIT will not necessarily get the same LU as the original one.)

3.6.1 Supplied Parameters

The application supplies the following parameters:

lua_verb

LUA_VERB_RUI

lua_verb_length

The length in bytes of the LUA verb record. Set this to sizeof(struct LUA_COMMON).

lua_opcode

LUA_OPCODE_RUI_REINIT

lua_correlator

Optional. A four-byte value that you can use to correlate this verb with other processing within your application. LUA does not use or change this information.

lua_luname

The name in ASCII of the LU that was being used by the failed session. This must match the name returned on the original RUI_INIT verb (not necessarily the same as the name that was supplied to the verb).

This parameter is required only if the lua_sid parameter is 0 (zero). If a session ID is supplied in lua_sid, LUA does not use this parameter.

This parameter must be eight bytes long; pad on the right with spaces, 0x20, if the name is shorter than eight characters.

lua_sid

The session ID of the session. This must match a session ID returned on the previous RUI_INIT verb for the failed session.

This parameter is optional; if you do not specify the session ID, you must specify the LU name for the session in the lua_luname parameter.

lua_post_handle

A pointer to a callback routine. If the verb completes asynchronously, LUA will call this routine to indicate completion of the verb. For more information, see Designing and Writing LUA Applications.

3.6.2 Returned Parameters

LUA always returns the following parameter:

lua_flag2.async

This flag is set to 1 if the verb completed asynchronously, or 0 if the verb completed synchronously. (RUI_REINIT will always complete asynchronously, unless it returns an error such as LUA_PARAMETER_CHECK.)

Other returned parameters depend on whether the verb completed successfully; see the following sections.

Successful Execution

If the verb executes successfully, LUA returns the following parameter:

lua_prim_rc

LUA_OK

Unsuccessful Execution

If a verb does not complete successfully, LUA returns a primary return code to indicate the type of error and a secondary return code to provide specific details about the reason for unsuccessful execution.

Verb Canceled

The following return codes indicate that the verb did not complete successfully because it was canceled by another verb:

lua_prim_rc

LUA_CANCELLED

lua_sec_rc

LUA_TERMINATED

An RUI_TERM verb was issued before the RUI_REINIT had completed.

Parameter Check

The following return codes indicate that the verb did not complete successfully because a supplied parameter was in error:

lua_prim_rc

LUA_PARAMETER_CHECK

lua_sec_rc

Possible values are:

LUA_INVALID_POST_HANDLE

The lua_post_handle parameter was not a valid pointer to a callback routine.

LUA_RESERVED_FIELD_NOT_ZERO

A reserved field in the verb record, or a parameter that is not used by this verb, was set to a nonzero value.

LUA_VERB_LENGTH_INVALID

The value of the lua_verb_length parameter was less than the length of the verb record required for this verb.

State Check

The following return codes indicate that the verb was issued in a session state in which it was not valid:

lua_prim_rc

LUA_STATE_CHECK

lua_sec_rc

Possible values are:

LUA_NO_RUI_SESSION

An RUI_INIT verb has not previously completed successfully for the specified LU name or session ID.

LUA_DUPLICATE_RUI_INIT

An RUI_REINIT verb is currently being processed for this session.

LUA_REINIT_INVALID

Session failure has not occurred for this session.

Other Conditions

The following return codes indicate that the verb record supplied was valid, but the verb did not complete successfully:

lua_prim_rc

LUA_UNSUCCESSFUL

lua_sec_rc

LUA_INVALID_PROCESS

The original RUI_INIT verb was issued from a different operating system process.

The following return codes indicate that the verb did not complete successfully for other reasons:

lua_prim_rc

LUA_COMM_SUBSYSTEM_NOT_LOADED

This return code indicates one of the following conditions:

  • The SNAP-IX software has not been started. The SNAP-IX software must be started before you can use LUA verbs. Contact your System Administrator if necessary.

  • There are no active SNAP-IX nodes. The local node that owns the requested LU, or a local node that owns one or more LUs in the requested LU pool, must be started before you can use LUA verbs. Contact your System Administrator if necessary.

  • The maximum number of users permitted by the SNAP-IX license are already using SNAP-IX. You cannot use this application at present because it would exceed the user limit; you may be able to start it later when there are fewer users on the system.

lua_prim_rc

LUA_COMM_SUBSYSTEM_ABENDED

A required SNAP-IX software component (such as the node) has terminated or has been stopped. Contact your System Administrator if necessary.

lua_prim_rc

LUA_SESSION_FAILURE

The LUA session has failed.

If the secondary return code is not LUA_RUI_LOGIC_ERROR , then this LU can be reinitialized using an RUI_REINIT. If it is not reinitialized, then an RUI_TERM must be issued before an RUI_INIT can be issued for the same LU.

lua_sec_rc

Possible values are:

LUA_LU_COMPONENT_DISCONNECTED

The LUA session has failed because of a problem with the communications link or with the host LU.

LUA_RUI_LOGIC_ERROR

This return code indicates one of the following:

  • The host system has violated SNA protocols

  • An internal error was detected within LUA

Attempt to reproduce the problem with SNA tracing active (contact your System Administrator if necessary), and check that the host is sending correct data. If this does not solve the problem, contact your SNAP-IX support personnel.

lua_prim_rc

LUA_INVALID_VERB

Either the lua_verb parameter or the lua_opcode parameter was not valid. The verb did not execute.

3.6.3 Interaction with Other Verbs

This verb can only be issued if a previous LUA verb has returned with primary return code LUA_SESSION_FAILURE , and with a secondary return code other than LUA_RUI_LOGIC_ERROR.

Until this verb has completed successfully, the only other LUA verb that can be issued for this session is RUI_TERM (which will terminate a pending RUI_REINIT).

3.6.4 Usage and Restrictions

The RUI_REINIT verb completes after an ACTLU is received from the host. If necessary, the verb waits indefinitely. If an ACTLU has already been received prior to the RUI_REINIT verb, the verb returns immediately with primary return code LUA_OK.

Once the RUI_REINIT verb has completed successfully, this session uses the LU for which the session was started. No other LUA session (from this or any other application) can use the LU until the RUI_TERM verb is issued, or until an LUA_SESSION_FAILURE primary return code is received.

If the secondary return code is not LUA_RUI_LOGIC_ERROR , then this LU can be reinitialized using an RUI_REINIT. If it is not reinitialized, then an RUI_TERM must be issued before an RUI_INIT can be issued for the same LU.

The session ID of the restarted session is the same as the session ID before the failure. Unlike RUI_INIT, RUI_REINIT does not return this session ID; the application should either use the session ID that was returned to the original RUI_INIT verb, or access the session using its LU name.

Previous Page Contents Page Top of Page Next page