Previous Topic: CONNECTION Statement—Specify the JNDI Name of the Connection FactoryNext Topic: CONNECTIONDOMAIN Statement—Specify a Domain for NTLM Connection Authentication


CONNECTION_FACTORY Statement—Specify the JNDI Name of the Connection Factory

The CONNECTION_FACTORY statement specifies the connection factory JNDI name in a JMS job.

Supported Job Types

This statement is required for the following job types:

Syntax

This statement has the following format:

CONNECTION_FACTORY factory
factory

Specifies the connection factory JNDI name. The connection factory contains all the bindings needed to look up the referenced topic or queue. JMS jobs use the connection factory to create a connection with the JMS provider.

Limits: Up to 1024 characters; case-sensitive

Notes:

Example: Specify Connection Factory in a JMS Publish Job

This example publishes the message "this is my message" to the queue named Queue. The Java class of the message is String. The initial context factory supplied by the JNDI service provider is com.ibm.websphere.naming.WsnInitialContextFactory. The service provider's URL is iiop://172.24.0.0:2809, where 172.24.0.0 is the IP address of the WebSphere MQ server and 2809 is the ORB port. The job uses the cyberuser JNDI user ID to gain access to the connection factory named ConnectionFactory.

AGENT APPAGENT
INITIAL_CONTEXT com.ibm.websphere.naming.WsnInitialContextFactory
LOCATION iiop://172.24.0.0:2809
CONNECTION_FACTORY ConnectionFactory
DESTNAME Queue
TOPIC N
MSGCLASS String
JNDIUSER cyberuser
PARAMETER TYPE(java.lang.String) VALUE('this is my message')

Note: The agent does not support JMS messaging on IBM WebSphere. If you have IBM WebSphere MQ, your agent administrator can set up the agent plug-in to run JMS Publish and JMS Subscribe for JMS queues. JMS topics are not supported on IBM WebSphere MQ.