The parameters
that are defined in XAOpenString are comma delimited and
positional. Represent missing optional parameters by a comma if you include
other parameters later in the string.
The following stanza
entry is an example that you can add when using WebSphere® MQ Java
as the JMS provider:
XAResourceManager:
Name=WBIWMQJMS
SwitchFile=/install_dir/lib/JMSSwitch.so
XAOpenString=<Initial Context Factory>,
<location of JNDI bindings>'
<LDAP Principal>,
<LDAP Credentials>,
<Recovery Connection Factory Name>,
<JMS Principal>,
<JMS Credentials>
ThreadOfControl=THREAD
where:
- install_dir
- Is the location of the WebSphere Event
Broker installation.
This value is mandatory where the LDAP parameters are omitted, but a user-defined
Queue Connection Factory is specified for recovery.
- <Initial Context Factory>
- Is the Initial Context Factory identifier for the JMS provider; this value
is required.
- <Location of JNDI bindings>
- Is either the file path to the bindings file, or the LDAP directory location
of the JNDI administered objects that can be used to create an initial context
factory for the JMS connection. When supplying the file path to the bindings
file, do not include the file name. See the JMSInput or JMSOutput node for further details
on creating the JNDI administered objects; this value is required.
- <LDAP Principal>
- Is an optional parameter used to specify the principal (user ID) that
might be required when an LDAP database is used to hold the JNDI administered
objects.
- <LDAP Credentials>
- Is an optional parameter used to specify the Credentials (password) that
might be required if a password protected LDAP database is used to hold the
JNDI administered objects.
- <Recovery Connection Factory Name>
- Is an optional parameter used to specify the name of a Queue Connection
Factory object in the JNDI administered objects for recovery purposes, when
the non default name is required.
- <JMS Principal>
- Is an optional parameter for the user ID required to connect to a JMS
provider, using a secure JMS Connection Factory.
- <JMS Credentials>
- Is an optional parameter for the password required to connect to the same
JMS provider in conjunction with the JMS principal.
The values for the Initial Context factory and
Location of JNDI bindings in the stanza must match the values that you specified
in the JMSInput or JMSOutput nodes
in the message flows.
All LDAP parameters must match the values
that you specified on the mqsicreatebroker or mqsichangebroker command.
The
Recovery Factory Name must match a Queue Connection Factory name that is created
in the JNDI administered objects. If you do not specify a name, a default
factory called recoverXAQCF is used. In either case, this
value must refer to a JNDI administered object that has already been created.
The JMS Principal and JMS Credentials must be configured together.
The following example shows the format of a stanza in the
qm.ini file
that describes a JMS provider for global transactions:
XAResourceManager:
Name=XAJMS_PROVIDER1
SwitchFile=/opt/var/mqsi/lib/JMSSwitch.so
XAOpenString= com.sun.jndi.fscontext.RefFSContextFactory,
/Bindings/JMSProvider1_Bindings_Directory,
,
,
,
myJMSuser1,
passwd
ThreadOfControl=THREAD
where:
- XAJMS_PROVIDER1
- Is the user-defined name for the resource manager
- /opt/var/mqsi
- Is the <Installation Path>
- com.sun.jndi.fscontext.RefFSContextFactory
- Is the <Initial Context Factory>
- /Bindings/JMSProvider1_Bindings_Directory
- Is the location of the bindings
- myJMSuser1
- Is the <JMS Principal>
- passwd
- Is the password used in <JMS Credentials>
In this example, the optional fields
<LDAP Principal>,
<LDAP
Credentials>, and
<Recovery Connection Factory Name> are
not required, therefore the positional comma delimiters only are configured
in the
XAOpenString stanza.