Previous topic |
Next topic |
Contents |
Contact z/OS |
Library |
PDF
![]() XCF Message User Routine z/OS MVS Programming: Writing Transaction Schedulers for APPC/MVS SA23-1398-00 |
|||||||||||||||||||||||||||||||
APPC/MVS invokes a transaction scheduler's XCF message user routine to inform the transaction scheduler of general events affecting APPC/MVS, and to pass to it all inbound Allocate requests that are addressed to the transaction scheduler's LU. Depending on the message that APPC/MVS passes, the message user routine might have to issue the XCF IXCMSGI macro to obtain additional information. The transaction scheduler identifies its XCF message user routine to APPC/MVS on the Join_Sysappc_Group service. References
EnvironmentThe XCF message user routine receives control in the following environment:
ProcessingAll XCF messages sent by APPC/MVS contain a type code to indicate the type of message being sent. The type code is the first four bytes of the 32-byte message control area passed in the parameter list (mapped by IXCYMEPL) to the message user routine. The user routine must examine the type code to determine whether it is a general event message or an Allocate request message. The user routine should be optimized to handle requests to allocate TPs, because these will be the most common. Note: Messages requesting the transaction scheduler to allocate a
TP will not be sent until APPC/MVS activates at least one of the transaction
scheduler's LUs. However, because XCF messages might be delivered
out of sequence, the XCF message user routine might receive an Allocate
TP request message before it receives the message reporting that the
LU is active. Also, the message user routine is not single-threaded;
several processors may execute the user routine simultaneously, with
each processor handling a different message.
z/OS MVS Programming: Sysplex Services Guide contains general information about designing and coding an XCF message user routine; you should be familiar with that information before coding the message user routine for a transaction scheduler. The rest of this section contains guidance that applies only to designing a message user routine for use with a transaction scheduler for APPC/MVS. Message TypesThe contents of the 32-byte message control area (MEPLCNTL field)
indicate that the XCF message is one of the following types:
The ATBXCFMS mapping macro maps these APPC/MVS messages. The general event message for APPC initialization/termination is small enough to be contained in the 32-byte message control area. However, the LU activation/deactivation and the Allocate TP request messages are each too large to fit in the 32-byte message control area. Also, for the LU activation/deactivation message, additional information is available if optional data was supplied for the transaction scheduler's LU in the USERVAR, ALTLU, and GRNAME keywords on the LUADD statement in the APPCPMxx parmlib member. In these cases, the message user routine must issue the XCF IXCMSGI macro to receive the rest of the message or the additional information. When you design the message user routine to issue the IXCMSGI macro, provide the message token value in the MEPLMTOK field of the parameter list. Also provide a buffer to contain the data returned by IXCMSGI; the storage key for the buffer must match the PSW key of the caller of Join_Sysappc_Group. You may receive data in a single or in multiple buffers. See z/OS MVS Programming: Sysplex Services Guide for information about designing a message user routine to use single or multiple buffers without encountering errors. Programming Notes for LU Activation/Deactivation MessagesFor LU activation/deactivation messages:
Programming Notes for Allocate TP Request MessagesIf the message user routine issues IXCMSGI for more data, but the IXCMSGI macro fails, the message user routine should call the Cleanup_TP service to clean up any outstanding APPC/MVS resources, supplying the TP_ID that was passed to the message user routine in the 32-byte control area. If the IXCMSGI macro successfully returns to the message user routine, the buffer contains the Allocate TP request message, which includes such data as:
For more information about the RACF Security_Token and ENVR_Object, see z/OS Security Server RACROUTE Macro Reference. Programming Considerations
Entry SpecificationsXCF passes information to the message user routine in registers and in a parameter list. Registers at EntryOn entry to the message user routine, the registers contain the following information:
Parameter List ContentsThe parameter list that XCF passes to the message user routine
is mapped by the IXCYMEPL mapping macro and is pointed to by GPR 1.
The parameter list is addressable from the primary address space in
which the message user routine runs, and includes the following information:
Figure 1
illustrates how APPC/MVS messages are mapped.
Figure 1. How APPC/MVS Messages are Mapped
![]() Return SpecificationsOn return, the message user routine does not have to set any return codes or place any information in the GPRs. The message user routine must return control through a BR 14 or a BSM 0,14. ![]() ![]() ![]() |
![]() |