Writing a PLTPI program to start the connection to WebSphere MQ
You can write your own PLTPI program to start the CICS®-WebSphere® MQ connection, based on the sample DFHMQPLT, which is supplied in the SDFHSAMP library.
About this task
Although this sample is written in assembler language, you can write your own program in any language supported by CICS. For more information about writing CICS PLTPI programs, see Writing initialization and shutdown programs.
Your PLTPI program must link to the CICS-WebSphere MQ adapter program DFHMQQCN, and pass a parameter list that specifies the connection values to be used. The parameter list is described in Starting a connection by linking to DFHMQQCN from a CICS application program.
Procedure
EXEC CICS LINK PROGRAM('DFHMQQCN')
COMMAREA(CONNPL) LENGTH(length of CONNPL)
In this example, the parameter list is named CONNPL. Because no terminals are available at this stage of CICS starting, you must use the
COMMAREA option to pass the parameter list. Results
If you are using MQ monitors, when the MQ connection
is started, the MQ monitors are started automatically provided that the MQMONITOR resources have
been installed with attributes AUTOSTART(YES) and STATUS(ENABLED).