2 Setting Up Inbound and Outbound WebSphere MQ Queues for Z Events Only

IBM WebSphere MQ is a queue messaging system that requires a sender and receiver relationship. One side of IBM WebSphere MQ is installed on Oracle's JD Edwards EnterpriseOne server while the related side is installed on another physical or logical machine. The setup on the JD Edwards EnterpriseOne server enables JD Edwards EnterpriseOne to receive inbound messages from a third-party application or system and to place outbound messages in a queue for processing by a third-party application or system. Refer to the applicable IBM documentation for instructions on installing IBM WebSphere MQ on other machines.

This chapter contains the following topics:

2.1 Setting Up Inbound and Outbound WebSphere MQ Queues for Z Events Only: Step 1

The procedures described in this section assume you have already installed the IBM product WebSphere MQ onto your JD Edwards EnterpriseOne server.

You must set up your JD Edwards EnterpriseOne server so that the system can receive inbound messages from a third-party application or system and then place responses, in the form of outbound messages, in a queue for processing by the third-party application or system.

In addition to information about setting up your JD Edwards EnterpriseOne server, this section also provides examples for communicating between the JD Edwards EnterpriseOne server and a third-party server.

Prerequisites

On your iSeries system, you must remove QMQM from the system value QSYSLIBL. After that you must issue a subsystem call with a qualified library name, which is required because the subsystem must be up and running before you can proceed with any other queue manager instructions. Type this command:

STRSBS QMQM/QMQM

Also, you must use one of these commands to change your user preferences:

CHGUSRPRF USRPRF(EnterpriseOne) GRPPRF(QMQMADM)

or

CHGUSRPRF USRPRF(EnterpriseOne) SUPGRPPRF(QMQMADM)

2.2 Configuring the JD Edwards EnterpriseOne Server Components

Inbound to JD Edwards EnterpriseOne and Outbound to a Third-Party System

You set up your JD Edwards EnterpriseOne server so that the system can receive an inbound message from a third-party system or application and respond by placing an outbound message in the outbound queue. Complete these tasks:

  • Create the WebSphere MQ Queue Manager.

  • Start the WebSphere MQ Queue Manager.

  • Create MQ local queues.

  • Create a MQ remote queue.

  • Create a MQ local sender channel.

  • Create a MQ local receiver channel.

  • Grant authority to all queues and channels.

  • Reset a channel.

Caution:

The names of queues and channels in IBM WebSphere MQ are case-sensitive. Be sure to use capital letters as specified in this document. You can specify any name for a queue or channel. However, it is important that the queue names you create match the queue names you specify in the jde.ini file on the JD Edwards EnterpriseOne server.

To create the IBM WebSphere MQ Queue Manager

On the JD Edwards EnterpriseOne server, create the IBM WebSphere MQ Queue Manager by issuing this command from the iSeries Command Entry command line:

CRTMQM MQMNAME(JDE_QMGR) TEXT('JD Edwards queue manager') DFTQMGR(*YES)

To start the IBM WebSphere MQ Queue Manager

  1. On the JD Edwards EnterpriseOne server, start the IBM WebSphere MQ Queue Manager by issuing this command on the command line:

    STRMQM MQMNAME(JDE_QMGR)
    
  2. The display returns this:

    Ownership of object QXCSGLOBAL in QTEMP type *USRSPC changed. 
    Ownership of object QXCSGLOBAL in QTEMP type *USRSPC changed. 
    Ownership of object QXSX455240 in QMQMDATA type *USRQ changed. 
    Ownership of object QXSX455240 in QMQMDATA type *USRQ changed. 
    Ownership of object QMQMLOCAL in QTEMP type *USRSPC changed. 
    Ownership of object QMQMLOCAL in QTEMP type *USRSPC changed. 
    Ownership of object QXSA00021 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00021 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00022 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00022 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00023 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00024 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00024 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00025 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00025 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSZ00006 in QMQMDATA type *USRQ changed. 
    Ownership of object QXSZ00006 in QMQMDATA type *USRQ changed. 
    Ownership of object QXSA00026 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00026 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSZ00007 in QMQMDATA type *USRQ changed. 
    Ownership of object QXSZ00007 in QMQMDATA type *USRQ changed. 
    Ownership of object QXSB00005 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00027 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00027 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSZ00008 in QMQMDATA type *USRQ changed. 
    Ownership of object QXSZ00008 in QMQMDATA type *USRQ changed. 
    Ownership of object QXSA00028 in QMQMDATA type *USRSPC changed.
    Ownership of object QXSA00028 in QMQMDATA type *USRSPC changed.
    11 entries received from journal AMQAJRN in QUSRSYS.   
    Ownership of object QXLEQ00001 in QMQMDATA type *USRQ changed. 
    Ownership of object QXLEQ00001 in QMQMDATA type *USRQ changed. 
    Object QXSX455240 in QMQMDATA type *USRQ deleted.    
    Message Queue Manager started
    

To create MQ local queues

You must create these local queues:

  • INBOUND.Q

  • SUCCESS.Q

  • ERROR.Q

  • DEFRES.Q

  • OUTBOUND.Q.XMIT

Access the JD Edwards EnterpriseOne server.

  1. To change the default local queue, enter this command on the command line:

    CHGMQMQ QNAME(SYSTEM.DEFAULT.LOCAL.QUEUE) QTYPE(*LCL)  
    TEXT('Default local queue') PUTENBL(*YES) DFTPTY(9)  
    DFTMSGPST(*YES) PRCNAME(*NONE) TRGENBL(*NO) GETENBL(*YES) 
    SHARE(*YES) DFTSHARE(*YES) MSGDLYSEQ(*FIFO) HDNBKTCNT(*YES)
    TRGTYPE(*NONE) TRGDEPTH(1) TRGMSGPTY(0) TRGDATA(*NONE)  
    RTNITV(999999999) MAXDEPTH(640000) MAXMSGLEN(4194304)  
    BKTTHLD(0) BKTQNAME(*NONE) INITQNAME(*NONE) USAGE(*NORMAL) 
    HIGHTHLD(100) LOWTHLD(0) FULLEVT(*YES) HIGHEVT(*YES)  
    LOWEVT(*YES) SRVITV(999999999) SRVEVT(*NONE) DISTLIST(*NO)
    
  2. To create the local queues, enter these IBM WebSphere MQ commands:

    CRTMQMQ QNAME(INBOUND.Q) QTYPE(*LCL)
    TEXT('JD Edwards EnterpriseOne inbound queue') 
    PUTENBL(*YES) DFTPTY(9) DFTMSGPST(*YES)
     
    CRTMQMQ QNAME(SUCCESS.Q) QTYPE(*LCL)
    TEXT(' JD Edwards EnterpriseOne success queue') 
    PUTENBL(*YES) DFTPTY(9) DFTMSGPST(*YES)
     
    CRTMQMQ QNAME(ERROR.Q) QTYPE(*LCL)
    TEXT(' JD Edwards EnterpriseOne error queue') 
    PUTENBL(*YES) DFTPTY(9) DFTMSGPST(*YES)
     
    CRTMQMQ QNAME(DEFRES.Q) QTYPE(*LCL) 
    TEXT(' JD Edwards EnterpriseOne default response queue')
    PUTENBL(*YES) DFTPTY(9) DFTMSGPST(*YES)
     
    CRTMQMQ QNAME(OUTBOUND.Q.XMIT) QTYPE(*LCL)
    TEXT(' JD Edwards EnterpriseOne inbound queue') 
    PUTENBL(*YES) DFTPTY(9) DFTMSGPST(*YES)
    USAGE(*TMQ)
    

To create the MQ remote queue

Access the JD Edwards EnterpriseOne server.

  1. To change the default remote queue, enter this command on the command line:

    CHGMQMQ QNAME(SYSTEM.DEFAULT.REMOTE.QUEUE)
    QTYPE(*RMT)              
    TEXT('Default remote queue') PUTENBL(*YES)
    DFTPTY(9) DFTMSGPST(*YES) TMQNAME(*NONE) 
    RMTQNAME(' ') RMTMQMNAME(' ') 
    
  2. To create the live remote queue, enter this command:

    CRTMQMQ QNAME(OUTBOUND.Q) QTYPE(*RMT)     
    TEXT('JD Edwards EnterpriseOne outbound queue to NC system')
    TMQNAME(OUTBOUND.Q.XMIT) RMTQNAME(ECE_IN2MQI) 
    RMTMQMNAME(ECE_MQI_QMGR)
    

    Note:

    ECE_IN2MQI is the third-party remote queue name and ECE_MQI_QMGR is the third-party queue manager name.

To create a MQ local sender channel

Access the JD Edwards EnterpriseOne server.

  1. To change the default local sender channel, enter this command on the command line:

    CHGMQMCHL CHLNAME(SYSTEM.DEF.SENDER) 
    CHLTYPE(*SDR ) TRPTYPE(*TCP) 
    TEXT('Default Sender channel') CONNAME(' ')
    TMQNAME(' ') BATCHSIZE(9999) DSCITV(0) 
    SHORTTMR(999999999) SHORTRTY(999999999) 
    LONGTMR(999999999) SCYEXIT(*NONE) 
    SCYUSRDATA(*NONE) SNDEXIT(*NONE) 
    SNDUSRDATA(*NONE) RCVEXIT(*NONE) 
    RCVUSRDATA(*NONE) MSGEXIT(*NONE) 
    MSGUSRDATA(*NONE) SEQNUMWRAP(999999999) 
    MAXMSGLEN(4194304) CVTMSG(*NO) 
    HRTBTINTVL(999999) NPMSPEED(*FAST)
    
  2. To create the live local sender channel, enter this command{

    CRTMQMCHL CHLNAME(OW2MQI_CHL) CHLTYPE(*SDR ) 
    TRPTYPE(*TCP) TEXT('Sender channel to NC system')
    CONNAME('NC Server Name') TMQNAME(OUTBOUND.Q.XMIT)
    

To create an MQ local receiver channel

Access the JD Edwards EnterpriseOne server.

  1. To change the default local receiver channel, enter this command on the command line:

    CHGMQMCHL CHLNAME(SYSTEM.DEF.RECEIVER) 
    CHLTYPE(*RCVR) TRPTYPE(*TCP) 
    TEXT('Default Receiver channel') BATCHSIZE(9999)
    SCYEXIT(*NONE) SCYUSRDATA(*NONE) SNDEXIT(*NONE) 
    SNDUSRDATA(*NONE) RCVEXIT(*NONE) 
    RCVUSRDATA(*NONE) MSGEXIT(*NONE) 
    MSGUSRDATA(*NONE) PUTAUT(*DFT) 
    SEQNUMWRAP(999999999) MAXMSGLEN(4194304) 
    HRTBTINTVL(999999) NPMSPEED(*FAST)
    
  2. To create the live local receiver channel, enter this command:

    CRTMQMCHL CHLNAME(MQI2OW_CHL ) CHLTYPE(*RCVR)TRPTYPE(*TCP) TEXT('Receiver channel from third-party system')
    

To grant authority to all queues and channels

You need to give authority to JD Edwards EnterpriseOne and to all of the queues and channels.

Access the JD Edwards EnterpriseOne server.

Enter these commands on the command line:

GRTMQMAUT OBJ(JDE_QMGR) OBJTYPE(*MQM)
 USER(JD Edwards EnterpriseOne) AUT(*ALL)
 
GRTMQMAUT OBJ(DEFRES.Q) OBJTYPE(*Q)
 USER(JD Edwards EnterpriseOne) AUT(*ALL)
 
GRTMQMAUT OBJ(ERROR.Q) OBJTYPE(*Q)
 USER(JD Edwards EnterpriseOne) AUT(*ALL)
 
GRTMQMAUT OBJ(INBOUND.Q) OBJTYPE(*Q)
 USER(JD Edwards EnterpriseOne) AUT(*ALL)
 
GRTMQMAUT OBJ(OUTBOUND.Q) OBJTYPE(*Q)
 USER(JD Edwards EnterpriseOne) AUT(*ALL)
 
GRTMQMAUT OBJ(SUCCESS.Q) OBJTYPE(*Q)
 USER(JD Edwards EnterpriseOne) AUT(*ALL)
 
GRTMQMAUT OBJ(SYSTEM.DEFAULT.LOCAL.QUEUE) OBJTYPE(*Q)
 USER(JD Edwards EnterpriseOne) AUT(*ALL)
 
GRTMQMAUT OBJ(SYSTEM.DEFAULT.REMOTE.QUEUE) OBJTYPE(*Q)
USER(JD Edwards EnterpriseOne) AUT(*ALL)

To reset a channel

If a channel becomes inactive, you can use this command to reset the channel:

RSTMQMCHL CHLNAME(channel_name)

2.3 Communicating Between Systems - Starting Up Channels And Listeners

You must set up communications between the JD Edwards EnterpriseOne server and the third-party system. This section provides examples for setting up communications. The example communications setup uses these sequenced and machine-dependent steps:

  • Start the Queue Manager on the third-party IBM WebSphere MQ server.

  • Start the Queue Manager on the JD Edwards EnterpriseOne IBM WebSphere MQ Server.

  • Start the channel on the third-party IBM WebSphere MQ Server.

  • Start the channel on the JD Edwards EnterpriseOne IBM WebSphere MQ Server.

Note:

The first time you start your communications channels, you might need to manually start the sender channel on the local machine and then manually start the receiver channel on the remote machine. After the initial start of the channels, the receiver on the remote machine should automatically start when you start the sender on the local machine.

To start the queue manager on the third-party WebSphere MQ server

Access the third-party WebSphere MQ server.

  1. At a DOS prompt, enter this command to start the Queue Manager:

    STRMQM MQMNAME(ECE_MQI_QMGR)
    
  2. At the DOS prompt, enter this command to start the listener:

    start/min runmqlsr -m ECE_MQI_QMGR -t TCP
    

    This action creates a minimized DOS prompt window. Do not close this window.

Note:

ECE_MQI_QMGR is the third-party queue manage name.

To start the queue manager on the JD Edwards EnterpriseOne IBM WebSphere MQ server

Access the JD Edwards EnterpriseOne IBM WebSphere MQ server.

  1. Enter this command to start the Queue Manager:

    STRMQM MQMNAME(JDE_QMGR)
    
  2. Enter this command to start the listener:

    STRMQMLSR
    

To start the channel on the third-party WebSphere MQ server

Access the third-party IBM WebSphere MQ server, and enter this command at the DOS prompt:

START CHANNEL(MQI2OW_CHL)

To start the channel on the JD Edwards EnterpriseOne IBM WebSphere MQ server

Access the JD Edwards EnterpriseOne IBM WebSphere MQ server, and enter this command:

STRMQMCHL CHLNAME(OW2MQI_CHL)

Alternately, you can create and run a CL script:

RUNMQSC ECE_MQI_QMGR
START CHANNEL(MQI2OW_CHL)
/*START CHANNEL(OW2MQI_CHL)*/
END

Note:

ECE_MQI_QMGR is the third-party queue manager name.