Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved


Chapter 8 Using the TIBCO Service Gateway for IMS TM : Getting Access to IMS TM Data

Getting Access to IMS TM Data
Overview of the IMS TM Logger Exit
After writing a record to the IMS/DB database, if IMS TM ascertains that it is appropriate according to user-supplied parameters, it calls the Logger Exit routine, DFSFLGX0, if it exists. IMS passes to the exit routine all log data after the data is all written to the IMS log. You use DFSFLGX0 to pass the log data to TIBCO Object Service Broker for processing.
Format 1 DATAIN
Each field is 4 bytes long; COUNT contains the value of 2
Function-Specific parameter list
The parameter list is pointed to by ADDRESS1 and the length, 40 bytes, is in LENGTH1
This field has been left here for backward compatibility. The old timestamp format value is in the 00YYDDDF HHMMSSTF format.
Address of the IMS log block data that has been successfully written to the OLDS/SLDS. (This can be a copy of the original IMS buffer.)
This field contains the current data and time fields, but in the IMS internal packed-decimal format. For further information on the internal packed-decimal time-stamp format, refer to IMS Version 7 Application Programming: Transaction Manager or IMS Version 7 Database Recovery Control (DBRC) Guide and Reference, or subsequent manuals.
This field contains the current date and time fields, but in the IMS internal packed-decimal format. For further information on the internal packed-decimal time-stamp format, refer to IMS Version 7 Application Programming: Transaction Manager or IMS Version 7 Database Recovery Control (DBRC) Guide and Reference, or subsequent manuals. Refer the LGWXTOD field for the timestamp format used prior to IMS/ESA V6.
IMS Log block data
The block is pointed to by ADDRESS2 and the length is in LENGTH2.
Logger Exit Processing
IMS calls the Logger Exit routine with an initialization call when the logger is opened and with a termination call when the logger is closed. IMS also calls the exit routine and passes log data to it with a write call whenever a block of data is written to the logger.
The Logger Exit routine uses the TIBCO Object Service Broker Call Level Interface to communicate with TIBCO Object Service Broker.
To use this exit routine:
 
1.
Using IEBCOPY, copy the IMS Logger Exit routine S6BFLGX0 and its alias DFSFLGX0 as one entity into either the IMS.SDFSRESL library or another PDS data set concatenated to STEPLIB. This library must be a PDS data set. If the library is a PDSE or the module is not present in STEPLIB, the IMS Transaction Manager control region will not load the exit nor issue any error message.
2.
Include the TIBCO Object Service Broker supplied $HLQNONV$.$INSTVER$.AUTH library in the STEPLIB concatenation in the IMS control region.
 
//STEPLIB DD DISP=SHR,DSN=IMS.SDFSRESL
// DD DISP=SHR,DSN=customer.pds.containing.DFSFLGX0
...
// DD DISP=SHR,DSN=$HLQNONV$.$INSTVER$.AUTH
...
 
Add a //HRNLIB DD statement pointing to the $HLQNONV$.$INSTVER$.AUTH library:
 
//HRNLIB DD DISP=SHR,DSN=$HLQNONV$.$INSTVER$.AUTH
 
3.

 
* This HRNIN is for IMS Logger exit routine, DFSFLGX0
CLIMSGLENMAX=0M,
EXECLOCALSIZE=128K,
EXECSTACKSIZE=128K,
TASKEXECNUM=1,
TASKFILENUM=1,
TASKINITNUM=2,
TASKMISCNUM=1,
TASKOPERNUM=1,
TASKSORTNUM=1,
* EE PARM
TDS=dob_name,
STANDBY=5,
* Session PARM
U=user_name, for example USR40
P=password,
* Transaction options
LIBRARY=library_name, for example IMSLOGER
SEARCH=L

 
4.
5.
6.
The Logger exit will pass to the IMS_LOGGER rule a DATAIN area containing 2 format1 blocks of data: the first block is the IMS function-specific parameter list and the second block is the IMS log block. For details refer to Format 1 DATAIN, and the IBM manual: IMS Customization Guide (SC26-9427-05)
Example of Messages
Example 1:

 
DFSFLGX0 - LGXINIT STARTEE error, RETCODE=0003, RETDATA=0033
*DFSFLGX0 - Logger Exit Routine disabled
DFSFLGX0 - Reply GO to re-enable Exit Routine when problem is corrected
DFSFLGX0 -Reply END at IMS shutdown to clear this message and end the WTOR task
*30 DFSFLGX0 - Reply GO or END
R 30,GO
*DFSFLGX0 - Logger Exit Routine re-enabled and WTOR task terminated

 
This group of messages indicates:
END – if the problem can not be corrected without re-cycling the IMS, then reply END to the WTOR message to end the WTOR task so that IMS can be shutdown gracefully.
Example 2:

 22:27:00 IMS_LOGGER rule: ENTERING LIB=IMSLOGER,RULE=IMS_LOGGER !
 22:27:00 IMS LOGGER rule: GOING TO SLEEP FOR 200000 MILLI-SECONDS.
DFSFLGX0 - LGXWRITE CALLRULE error, RETCODE=000D, RETDATA=0000
DFSFLGX0 - CLI request timed out
*DFSFLGX0 -Logger Exit Routine disabled
DFSFLGX0 -Reply GO to re-enable Exit Routine when problem is corrected
DFSFLGX0 -Reply END at IMS shutdown to clear this message and end the
WTOR task
*31 DFSFLGX0 - Reply GO or END
R 31,END
*DFSFLGX0 - WTOR task terminated

 
This group of messages indicates:
The Exit was doing the CALLRULE operation and was timed out, in this case the IMS_LOGGER rule was deliberately in a “wait” and the wait time is longer than the timeout interval set by the CLITIMEOUTLIMIT= value.
Refer to TIBCO Object Service Broker Parameters for information about the CLITIMEOUTLIMIT Execution Environment parameter.
END – if the problem can not be corrected without re-cycling the IMS, then reply END to the WTOR message to end the WTOR task so that IMS can be shutdown gracefully (illustrated in this case).

Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved