5.15.3 CONNECT

The CONNECT command is used to open a connection to the enterprise messaging system.

The currently available vendor implementations are ActiveMQ, SonicMQ, Tibco Enterprise Messaging Service and WebSphereMQ.

It is possible to create more vendor implementations by writing a Java class that implements the JMSVendor interface.

The JMSFileService does a service properties lookup using the VENDOR keyword value to determine which Java class will be used to create the connection object.

vendor.sonicmq=com.acme.service.JMSVendorSonicMQ

vendor.tibcomq=com.acme.service.JMSVendorTibcoMQ

vendor.activemq=com.acme.service.JMSVendorActiveMQ

vendor.webspheremq=com.acme.service.JMSVendorMQSeries

Keyword values can also be passed to the CONNECT command by using a working list argument. The first column supplies the keyword name and the second column the keyword value.

The command keyword takes precedence over the working list keyword value entry.

Syntax:

Command

Keyword

Value

Developer notes

CONNECT

VENDOR

Value

Required. Message System Vendor.

HOST

value

Required. Hostname.

PORT

value

Optional.
Default is 2506 for SonicMQ.
Default is 7222 for TibcoMQ.
Default is 61616 for ActiveMQ.
Default is 1414 for WebSphereMQ.

USER

value

Optional.

PASSWORD

value

Optional.

CLIENTID

value

Optional.

QUEUE

value

Required.

REPLYTO

*TEMPORARY

Optional. Create and use a temporary reply queue.

CHANNEL

value

Conditional. Required for WebSphereMQ connection.

QUEUE-MANAGER

value

Optional. Used by WebSphereMQ connection.

CIPHER-SUITE

value

Optional. Used by WebSphereMQ connection.

MESSAGE-PRIORITY

value

0 (lowest) to 9 (highest).
Default is 4.

MESSAGE-DELIVERY

*PERSISTENT

Default.

*NONPERSISTENT

 

MESSAGE-TIME-TO-LIVE

value

Default is 0 milliseconds.
A value of 0 means keep forever.

SESSION-TRANSACTED

*YES

 

*NO

Default.

SESSION-ACKNOWLEDGE

*AUTO

Default.

*CLIENT

 

*DUPOK

 

 

Example

CONNECT VENDOR(WEBSPHEREMQ) HOST(LOCALHOST) CHANNEL(USERAGENT.CHANNEL) QUEUE-MANAGER(USERAGENT.QUEUE.MANAGER) QUEUE(USERAGENT.QUEUE) #WRKLIST(KEYWRD,KEYVAL)

 

CONNECT VENDOR(ACTIVEMQ) HOST(LOCALHOST) QUEUE(QUEUE_1) #WRKLIST(KEYWRD,KEYVAL)