Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Published by Scroll Versions from space FUNCTDEV and version SVC2024.1

This topic provides a reference for configuring SOAtest for popular JMS providers.
Sections include:

Table of Contents
maxLevel1

...

Any time that a username and password are required to connect to a JMS system that is configured to require authentication for JNDI access, the following JNDI properties must be configured:

  • java.naming.security.principal=<USERNAME>
  • java.naming.security.credentials=<PASSWORD>

Amazon Simple Queue Service (SQS)

...

For

Amazon Simple Queue Service (SQS) and other JMS providers where building JMS ConnectionFactory through JNDI lookup is difficult.

Minimum required JARs

Amazon SQS java client JARs (available on Maven Central at https://repo1.maven.org/maven2/com/amazonaws/download from Maven Central here):

  • amazon-sqs-java-messaging-lib-1.1.x.jar
  • aws-java-sdk-sqs-1.12.x.jar
  • aws-java-sdk-core-1.12.x.jar
  • aws-java-sdk-sts-1.12.x.jar

WSO2 carbon-jndi JAR (available on download from the WSO2 Maven repository at https://maven.wso2.org/nexus/content/repositories/releases/org/wso2/carbon/jndi/org.wso2.carbon.jndi/here):

org.wso2.carbon.jndi-<version><VERSION>.jar

Factory class

org.wso2.carbon.jndi.internal.InMemoryInitialContextFactory

InMemoryInitialContextFactory from the WSO2 carbon-jndi project. See Creating the JMS ConnectionFactory Object.

Connecting to AWS

Use I AM user roles for connecting to AWS. Refer to the following Amazon documentation for details:

Learn more

https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/getting-started.html

https://github.com/awslabs/amazon-sqs-java-messaging-lib/tree/master/src/main/java/com/amazon/sqs/javamessaging

Anchor
CreatingJMSConnectionFactory
CreatingJMSConnectionFactory
Creating the JMS ConnectionFactory Object

The following Groovy script is provided to help you create a JMS ConnectionFactory object and bind it to an in-memory InitialContext (bindConnectionFactory method). Run the script once per SOAtest or Virtualize startup. You can run the script using an Extension tool (for example, setup test in a SOAtest .tst or a Virtualize .pvn) for each .tst that requires the object or implement a more sophisticated process that automates script execution in a manner suitable to your environment. 

The script supports two methods of authenticating with AWS. If your SOAtest/Virtualize server is deployed within an AWS environment, AWS recommends using the instance provider flow for authentication. Alternatively, you can authenticate with AWS using the static mode, which requires the region, accessKey, and secretKey. See Script Variables for information about the authentication variables defined in the script.

...

A SQSConnectionFactory will be created and bound to the name SQSConnectionFactory. Set the initial context to org.wso2.carbon.jndi.internal.InMemoryInitialContextFactory and connection factory to SQSConnectionFactory in any JNDI properties for looking up JMS ConnectionFactory.

...

You can create a Messaging Client and send/receive messages for one of the queues that were already defined. You will be able to also see all the expected JMS header properties, including message IDs.

Script Variables

The following table describes the variables used in the script:

...

accessKey

secretKey

region

Access key credentials for CLI, SDK, and API access.
serialNumberNumber that uniquely identifies the device if multi-factor authentication (MFA) is enabled. For virtual MFA devices, the serial number is the Amazon resource name (ARN) of the device as shown on the AWS security credentials page.
tokenCodeThe value returned by your MFA device, such as Google Authenticator.
durationSecondsThe value specifying how long the temporary MFA credentials will be valid.

Apache ActiveMQ

Scroll Table Layout
widths30%,70%

Changing the Consumer Polling Interval

The message consumer for the SQS JMS client uses a default long polling interval of 20 seconds. This means that it can take up to 20 seconds to receive a message from a queue, even if the message shows up before then. The polling interval can be changed with a script. Example (Groovy):

Code Block
languagegroovy
import com.amazon.sqs.javamessaging.SQSMessageConsumerPrefetch

void setMessageConsumerWaitTime() {
    SQSMessageConsumerPrefetch.WAIT_TIME_SECONDS = 1
}

Apache ActiveMQ

Scroll Table Layout
widths30%,70%

Found under the ActiveMQ installation directory
ForForFor Apache Active MQ
Minimum required jars- activemq-all-[version]<VERSION>.jar (download from Maven Central here)
Typical provider URL patterntcp://hostname:61616
Factory class

JNDI Initial Context factory class
- org.apache.activemq.jndi.ActiveMQInitialContextFactory

Default connection factory JNDI name
- ConnectionFactory

Learn morehttp://activemq.apache.org/jndi-support.html

Apache

...

ActiveMQ Artemis

Scroll Table Layout
widths30%,70%

For
For
Apache
Qpid
ActiveMQ Artemis
Minimum required
JARs
jars
Found in qpid

artemis-

java

jms-client-

{ver}.tar.gz from

all-<VERSION>.jar (download from Maven Central here)

http
qpid
download.html.

The jars vary depending on the version of Qpid. The jar for Qpid 0.8 includes the following:

  • backport-util-concurrent-2.2.jar
  • geronimo-jms_1.1_spec-1.0.jar
  • mina-core-1.0.1.jar
  • mina-filter-ssl-1.0.1.jar
  • qpid-all.jar
  • qpid-client-0.8.jar
  • qpid-common-0.8.jar
  • slf4j-api-1.6.1.jar
Connection URL JNDI propertyconnectionfactory.<jndiname> 
For example:
connectionfactory.local = amqp://user:password@clientid/testpath?brokerlist='tcp://localhost:5672'Factory class

JNDI Initial Context factory class
- org.apache.qpid.jndi.PropertiesFileInitialContextFactory

Learn more

https://cwiki.apache.org/qpid/how-to-use-jndi.html

 

...

Typical provider URL pattern

tcp://hostname:61616

Factory class

JNDI Initial Context factory class
- org.apache.activemq.artemis.jndi.ActiveMQInitialContextFactory

Default connection factory JNDI name
- ConnectionFactory

Learn more

https://activemq.apache.org/components/artemis/documentation/latest/using-jms.html

Apache Qpid

Scroll Table Layout
widths30%,70%

For
For GlassFish
Apache Qpid
Minimum required JARs

GlassFish 3 - Found under [GlassFish install directory]/glassfish/lib: - gf-client.jar

Note that the gf-client.jar references a few dozen other jars from the GlassFish 3 installation. You must reference gf-client.jar from the GlassFish installation directory so that the referenced jars can be found and loaded. GlassFish can be downloaded from http://glassfish.java.net/.

GlassFish 2 - Found under [GlassFish install directory]/lib:

- appserv-admin.jar
 - appserv-deployment-client.jar
 - appserv-ext.jar
 - appserv-rt.jar
 - javaee.jar
 - install/applications/jmsra/imqjmsra.jar

Typical provider URL patterniiop://yourhostname:3700Factory class

JNDI Initial Context factory class
- com.sun.enterprise.naming.SerialInitContextFactory

Note that GlassFish has another JNDI Initial Context factory class called "com.sun.appserv.naming.S1ASCtxFactory". This class has poor performance and should not be used. Use the mentioned SerialInitContextFactory class instead which is available in both GlassFish 2 and GlassFish 3.

NotesThe GlassFish client and GlassFish server perform a reverse DNS lookup on each other. If the server does not recognize the client's host name, then you can add the client's host name and IP address to the hosts file on the server. If the client does not recognize the server's host name, then you can add the server's host name and IP address to the hosts file on the client. The hosts file is typically /etc/hosts on Unix or %SystemRoot%\system32\drivers\etc\hosts on Windows.Learn more http://glassfish.java.net/

IBM WebSphere Application Server (WAS)

JMS 2.0 compatible jars from Qpid 1.11.0 (download from Apache here)

  • Add all the jars in apache-qpid-jms-1.11.0/lib except for the slf4j-api and jakarta.jms-api jars
Typical provider URL pattern

The path to a JNDI properties file. The file can be empty. If you specify a non-empty file then those properties will be merged with any other JNDI properties defined on the Properties tab. Alternatively, you can use NUL if using Windows or /dev/null if using Linux or macOS.

Examples:

  • NUL
  • /dev/null
  • C:\path\to\jndi.properties
Connection URL JNDI property

Register a ConnectionFactory in JNDI using the form connectionfactory.<JNDI_NAME> = <CONNECTION_URL>.

Example:

connectionfactory.qpidConnectionFactory=amqp://localhost:5672

Detail:

https://qpid.apache.org/releases/qpid-jms-1.11.0/docs/index.html#connection-uri

Factory class

JNDI Initial Context factory class
- org.apache.qpid.jms.jndi.JmsInitialContextFactory

Connection Factory

Use the JNDI name specified earlier in the connectionfactory.<JNDI_NAME> property.

Example:

qpidConnectionFactory

Learn more

https://qpid.apache.org/releases/qpid-jms-1.11.0/index.html

Azure Service Bus Standard Tier

Scroll Table Layout
widths30%,70%

For
For the WAS Default JMS provider. Parasoft recommends the use of IBM's JMS thin client that is provided by WAS 7.0 or later, and which can interoperate with WAS 6.0.2 and later.Minimum required JARs

Found under [WAS installation dir]/runtimes
- com.ibm.ws.ejb.thinclient_7.0.0.jar
 - com.ibm.ws.orb_7.0.0.jar
 - com.ibm.ws.sib.client.thin.jms_7.0.0.jar

Typical provider URL patterniiop://yourhostname:2809/Factory class

JNDI Initial Context factory class
- com.ibm.websphere.naming.WsnInitialContextFactory

Learn moreWebSphere Application Server Network Deployment, Version 7.0 documentation
Info

What if you don’t have WAS 7.0 or later?

If you aren’t using (or don’t have access to) a WAS 7 installation, download and install the IBM Client for JMS, which also works with WAS 6.0.2 and later:

  1. Download the JMS Client installer jar from http://www-01.ibm.com/support/docview.wss?uid=swg24012804.
  2. Follow the instructions on the download page to install both the JMS and JNDI jars for the Sun JRE. The command to install the client jars is similar to:
    "java -jar sibc_oeminst-o0902.06.jar jms_jndi_sun C:\ibmjms"
    The client jars will be installed under the lib folder.
  3. Add the JNDI property com.ibm.CORBA.ORBInit=com.ibm.ws.sib.client.ORB
    • For simplicity, this jndi property can be set globally in a jndi.properties file in the JRE's lib folder.
    • For the standalone build of this product, the JRE lib folder is under <INSTALL_DIR>/plugins/com.parasoft.ptest.jdk.eclipse.core.web.<OS>.<ARCH>_<VERSION>/jdk/jre/lib.
    • This JNDI property is not needed when using the jars from the WAS 7 runtimes folder.

...

Azure Service Bus Standard Tier

Minimum required JARs

JMS 2.0 compatible jars from Qpid 1.11.0 (download from Apache here)

  • Add all the jars in apache-qpid-jms-1.11.0/lib except for the slf4j-api and jakarta.jms-api jars
Typical provider URL pattern

The path to a JNDI properties file. The file can be empty. If you specify a non-empty file then those properties will be merged with any other JNDI properties defined on the Properties tab. Alternatively, you can use NUL if using Windows or /dev/null if using Linux or macOS.

Examples:

  • NUL
  • /dev/null
  • C:\path\to\jndi.properties
Connection URL JNDI property

Register a ConnectionFactory in JNDI using the form connectionfactory.<JNDI_NAME> = <CONNECTION_URL>.

Example:

connectionfactory.SBCF=amqps://<NAMESPACE>.servicebus.windows.net:5671?jms.username=<SAS_POLICY_NAME>&jms.password=<SAS_POLICY_KEY>

Factory class

org.apache.qpid.jms.jndi.JmsInitialContextFactory

Connection Factory

Use the JNDI name specified earlier in the connectionfactory.<JNDI_NAME> property.

Example:

SBCF

Licensing Restrictions

Only queues are accessible using the apache-qpid-jms client. Topics are available over JMS with the azure-servicebus-jms client with premium license tier.

Detail:

https://learn.microsoft.com/azure/service-bus-messaging/service-bus-premium-messaging#java-message-service-jms-support

Learn more

https://learn.microsoft.com/azure/service-bus-messaging/service-bus-java-how-to-use-jms-api-amqp

Azure Service Bus Premium Tier

Scroll Table Layout
widths30%,70%

For

Azure Service Bus Premium Tier

Minimum required JARs

azure-servicebus-jms-<VERSION>.jar (download from Maven Central here)

JMS 2.0 compatible jars from Qpid 1.11.0 (download from Apache here)

  • Add all the jars in apache-qpid-jms-1.11.0/lib except for the slf4j-api and jakarta.jms-api jars

org.wso2.carbon.jndi-<VERSION>.jar (download from the WSO2 Maven repository here)

Factory class

org.wso2.carbon.jndi.internal.InMemoryInitialContextFactory
See Creating the JMS ConnectionFactory Object.

Connection Factory

ServiceBusJmsConnectionFactory

See Creating the JMS ConnectionFactory Object.

Licensing Restrictions

The azure-servicebus-jms client jar requires the Azure Service Bus premium license tier. Use the apache-qpid-jms client for standard license tier. 
Detail:
https://learn.microsoft.com/azure/service-bus-messaging/service-bus-premium-messaging#java-message-service-jms-support

Learn more

https://github.com/Azure/azure-servicebus-jms
https://learn.microsoft.com/azure/service-bus-messaging/jms-developer-guide
https://learn.microsoft.com/azure/service-bus-messaging/how-to-use-java-message-service-20

Anchor
CreatingJMSConnection
CreatingJMSConnection
Creating the JMS ConnectionFactory Object

You first need the "connection string" for your Azure Service Bus namespace:
Endpoint=sb://<NAMESPACE>.servicebus.windows.net/;SharedAccessKeyName=<SAS_POLICY_NAME>;SharedAccessKey=<SAS_POLICY_KEY>

Detail: https://learn.microsoft.com/azure/connectors/connectors-create-api-servicebus?tabs=consumption#get-connection-string

The following Groovy script is provided to help you create a JMS ConnectionFactory object and bind it to an in-memory InitialContext (bindConnectionFactory method). Run the script once per SOAtest or Virtualize startup. You can run the script using an Extension tool (for example, setup test in a SOAtest .tst or a Virtualize .pvn) for each .tst that requires the object or implement a more sophisticated process that automates script execution in a manner suitable to your environment. 

Code Block
languagegroovy
import com.microsoft.azure.servicebus.jms.ConnectionStringBuilder
import com.microsoft.azure.servicebus.jms.ServiceBusJmsConnectionFactory
import com.microsoft.azure.servicebus.jms.ServiceBusJmsConnectionFactorySettings;

import java.util.Properties

import javax.naming.Context 
import javax.naming.InitialContext

void bindConnectionFactory() {
    Properties env = new Properties()
    env.put(Context.INITIAL_CONTEXT_FACTORY, "org.wso2.carbon.jndi.internal.InMemoryInitialContextFactory")
    Context ctx = new InitialContext(env)
    ConnectionStringBuilder connectionStringBuilder = new ConnectionStringBuilder("Endpoint=sb://<NAMESPACE>.servicebus.windows.net/;SharedAccessKeyName=<SAS_POLICY_NAME>;SharedAccessKey=<SAS_POLICY_KEY>")
    ServiceBusJmsConnectionFactorySettings connectionFactorySettings = new ServiceBusJmsConnectionFactorySettings();
    connectionFactorySettings.setShouldReconnect(false);
    ServiceBusJmsConnectionFactory sbConnectionFactory = new ServiceBusJmsConnectionFactory(connectionStringBuilder, connectionFactorySettings)
    ctx.rebind("ServiceBusJmsConnectionFactory", sbConnectionFactory)
}

Anchor
GlassFish
GlassFish
GlassFish MQ

Scroll Table Layout
widths30%,70%

ForGlassFish
Minimum required JARs

GlassFish 3 - Found under <GLASSFISH_INSTALL_DIR>/glassfish/lib:

 - gf-client.jar

Note that the gf-client.jar references a few dozen other jars from the GlassFish 3 installation. You must reference gf-client.jar from the GlassFish installation directory so that the referenced jars can be found and loaded. GlassFish can be downloaded from http://glassfish.java.net/.

GlassFish 2 - Found under <GLASSFISH_INSTALL_DIR>/lib:

 - appserv-admin.jar
 - appserv-deployment-client.jar
 - appserv-ext.jar
 - appserv-rt.jar
 - javaee.jar
 - install/applications/jmsra/imqjmsra.jar

Typical provider URL patterniiop://hostname:3700
Factory class

JNDI Initial Context factory class
- com.sun.enterprise.naming.SerialInitContextFactory

Note that GlassFish has another JNDI Initial Context factory class called "com.sun.appserv.naming.S1ASCtxFactory". This class has poor performance and should not be used. Use the mentioned SerialInitContextFactory class instead which is available in both GlassFish 2 and GlassFish 3.

NotesThe GlassFish client and GlassFish server perform a reverse DNS lookup on each other. If the server does not recognize the client's host name, then you can add the client's host name and IP address to the hosts file on the server. If the client does not recognize the server's host name, then you can add the server's host name and IP address to the hosts file on the client. The hosts file is typically /etc/hosts on Unix or %SystemRoot%\system32\drivers\etc\hosts on Windows.
Learn more http://glassfish.java.net/

IBM WebSphere Application Server (WAS)

Scroll Table Layout
widths30%,70%

ForWAS Default JMS provider. Parasoft recommends the use of IBM's JMS thin client that is provided by WAS 7.0 or later, and which can interoperate with WAS 6.0.2 and later.
Minimum required JARs

Found under <WAS_INSTALL_DIR>/runtimes
 - com.ibm.ws.ejb.thinclient_7.0.0.jar
 - com.ibm.ws.orb_7.0.0.jar
 - com.ibm.ws.sib.client.thin.jms_7.0.0.jar

Typical provider URL patterniiop://hostname:2809/
Factory class

JNDI Initial Context factory class
- com.ibm.websphere.naming.WsnInitialContextFactory

Learn moreWebSphere Application Server Network Deployment, Version 7.0 documentation
Info

What if you don’t have WAS 7.0 or later?

If you aren’t using (or don’t have access to) a WAS 7 installation, download and install the IBM Client for JMS, which also works with WAS 6.0.2 and later:

  1. Download the JMS Client installer jar from http://www-01.ibm.com/support/docview.wss?uid=swg24012804.
  2. Follow the instructions on the download page to install both the JMS and JNDI jars for the Sun JRE. The command to install the client jars is similar to:
    "java -jar sibc_oeminst-o0902.06.jar jms_jndi_sun C:\ibmjms"
    The client jars will be installed under the lib folder.
  3. Add the JNDI property com.ibm.CORBA.ORBInit=com.ibm.ws.sib.client.ORB
    • For simplicity, this jndi property can be set globally in a jndi.properties file in the JRE's lib folder.
    • For the standalone build of this product, the JRE lib folder is under <INSTALL_DIR>/plugins/com.parasoft.ptest.jdk.eclipse.core.web.<OS>.<ARCH>_<VERSION>/jdk/jre/lib.
    • This JNDI property is not needed when using the jars from the WAS 7 runtimes folder.

Anchor
IBM_Web
IBM_Web
IBM MQ

Scroll Table Layout
widths30%,70%

For

IBM MQ JMS provider

Minimum required JARs

Typical provider URL pattern

The directory path containing the .bindings file.

Example:

file:/C:/JNDI-Directory

Detailed example of running IBM MQ JMSAdmin to setup JMS Administered objects in the JNDI .bindings file

Detailed example of running IBM MQ Explorer to setup JMS Administered objects in the JNDI .bindings file

Scroll Table Layout
widths30%,70%

 

For

For the IBM MQ JMS provider

Minimum required JARs

For IBM MQ 9

You can find these under <IBM_MQ_INSTALL_DIR>/java/lib:

  • com.ibm.mq.allclient.jar.

For IBM MQ 8

You can find these under <IBM_MQ_INSTALL_DIR>/java/lib:

  • com.ibm.mq.allclient.jar.

For IBM MQ 7.0

You can find these under <IBM_MQ_INSTALL_DIR>/java/lib:

  • com.ibm.mq.jar
  • com.ibm.mqjms.jar
  • com.ibm.mq.commonservices.jar 
  • com.ibm.mq.headers.jar
  • com.ibm.mq.jmqi.jar
  • connector.jar
  • dhbcore.jar
  • com.ibm.mq.pcf.jar

You also need to download the following jar:

  • ME01: IBM MQ - Initial Context Factory — mqcontext.jar

For IBM MQ 6.0

You can find these under <IBM_MQ_INSTALL_DIR>/java/lib:

  • com.ibm.mq.jar
  • com.ibm.mqjms.jar - connector.jar
  • dhbcore.jar
  • jta.jar

You also need to download the following jars:

  • MS0B: IBM MQ Java classes for PCF — com.ibm.mq.pcf.jar
  • ME01: IBM MQ - Initial Context Factory — mqcontext.jar

IBM MQ Client Download

The jars from <IBM_MQ_INSTALL_DIR>/java/lib are also included in the MQ Client. The MQ 6 Client is no longer available from IBM. The MQ 7 Client is available at http://www-01.ibm.com/support/docview.wss?uid=swg24019253

Typical provider URL pattern

yourhostname:1414/SYSTEM.DEF.SVRCONN

Factory class

IBM MQ JNDI Initial Context factory class

- com.

ibm

sun.

mq

jndi.

jms

fscontext.

context.WMQInitialContextFactory

RefFSContextFactory

Connection Factory

ConnectionFactory name as defined in the .bindings file

SSL configuration

IBM JMS clients can achieve SSL connections by setting the appropriate properties in the initial context. Both IBM MQ and IBM JMS clients will set the same properties for SSL connectivity

.

JMS messaging without JNDI

Under the properties tab, define the following properties:
Name: Value
provider:  IBM MQ
queue.manager: [your queue manager name] <QUEUE_MANAGER_NAME>
channel: [your channel name] <CHANNEL_NAME>
port: [port number, <PORT> (the default IBM MQ port is 1414])
With this configuration, SOAtest/Virtualize will create the connection factory using the provided parameters as follows:

Code Block
  import com.ibm.mq.jms.*;
  ...
  MQConnectionFactory cf = new MQConnectionFactory();
  cf.setHostName(hostname);
  cf.setPort(port);
  cf.setQueueManager(queuemanager);
  cf.setChannel(channel);
  cf.setTransportType(JMSC.MQJMS_TP_CLIENT_MQ_TCPIP);   
  cf.setFailIfQuiesce(JMSC.MQJMS_FIQ_YES);
  cf.setUseConnectionPooling(true);


 Additional information

IBM's JNDI provider authenticates itself with the IBM MQ server by sending the user's login name. This is typically the username that was provided when logging into the workstation before starting SOAtest/Virtualize.

If the MQ server does not recognize the username, then your tool will fail with the error "javax.jms.JMSSecurityException: MQJMS2013: invalid security authentication supplied for MQQueueManager".

This error can be resolved by adding a Windows user account on the IBM MQ server machine. This account should 1) have the same username as the account on the local machine where SOAtest is running and 2) be a member of the "mqm" IBM MQ Administration Group.Alternatively, use a different username by changing the value of the user.name Java System property. This system property can be configured by starting SOAtest using soatest.exe -J-Duser.name=username where username is the username you want to use. In some configurations using an empty username via soatest/virtualize.exe -J-Duser.name= will work. Using SYSTEM for the user.name property may also work in some configurations. 

It is also possible to modify Java system properties during test suite execution by using an Extension Tool to call the java.lang.System.setProperty() method from Sun's Java API.

For more details on this error, see http://www.mqseries.net/phpBB/view-topic.php?t=40640.

Learn more

http

https://www

-01

.ibm.com/

software/integration/wmq/library/

http://publib.boulder.ibm.com/infocenter/wmqv7/v7r0/topic/com.ibm.mq.csqzaw.doc/jm10320_.htmdocs/ibm-mq/

JBoss JMS

Scroll Table Layout
widths30%,70%

ForFor JBoss JMS; the following jar list is based on JBoss 5.0
Minimum required JARs

Found under [JBoss install dir] <JBOSS_INSTALL_DIR>/client
 - jboss-javaee.jar
 - jnp-client.jar
 - jboss-logging-spi.jar
 - jboss-messaging-client.jar
 - jboss-aop-client.jar
 - jboss-remoting.jar
 - jboss-common-core.jar
 - trove.jar
 - javassist.jar
 - jboss-mdr.jar
 - concurrent.jar
 - log4j.jar
 - jboss-serialization.jar

Typical provider URL patternyourhostnamehostname
Factory class

JNDI Initial Context factory class
- org.jnp.interfaces.NamingContextFactory

Open Message Queue (OpenMQ)

...

Scroll Table Layout
widths30%,70%

ForFor  OpenMQ Server
Minimum required JARs

Found under [OpenMQ install dir] <OPENMQ_INSTALL_DIR>/mq/lib
 - fscontext.jar  
 - imq.jar
 - jms.jar

Typical provider URL patternyourhostnamehostname
Factory class

JNDI Initial Context factory class
- com.sun.jndi.fscontext.RefFSContextFactory

Learn morehttp://mq.java.net

Oracle Advanced Queuing  Queuing (AQ)

Scroll Table Layout
widths30%,70%

ForFor Oracle Advanced Queuing (AQ)
Minimum required JARs

From Oracle Database installation:
- server/rdbms/jlib/aqapi.jar 
- server/jdbc/lib/ojdbc6.jar

or

From Oracle Weblogic Server installation:
- server/lib/aqapi.jar 
- server/lib/ojdbc6.jar

Provider URLLeave this field empty.
JNDI initial context factory classoracle.jms.AQjmsInitialContextFactory
Connection factory JNDI name

One of the following:
- QueueConnectionFactory
- TopicConnectionFactory
- ConnectionFactory
- XAQueueConnectionFactory
- XATopicConnectionFactory
- XAConnectionFactory

Required JNDI properties

java.naming.security.principal=<username>  <USERNAME>  
java.naming.security.credentials=<password> <PASSWORD> 
db_url=jdbc:oracle:thin:@host:port:dbName

Queue/topic names

Prefix a queue name with Queues/ and a topic name with Topics/. For example:
Queue: Queues/<queue<QUEUE_name>  NAME> 
Topic: Topics/<topic<TOPIC_name>NAME>

Additional informationThe aqapi.jar from older version of Oracle Database, such as 10g, may be missing the Initial Context factory class. Use the jars from Oracle Database 11g or later. The latest Oracle Database Express Edition (XE) can be downloaded from oracle.com:
Oracle Database Express Edition 11g Release 2
Learn moreInteroperating with Oracle AQ JMS

...

Scroll Table Layout
widths30%,70%

ForFor Oracle BEA WebLogic
Minimum required JARs (thin client) *

Found under <WEBLOGIC_HOME>/wlserver_x/server/lib:
 - wljmsclient.jar 
 - wlclient.jar

Note that additional jars may be needed. We recommend using a full client; this relieves you from having to find and add many jars.

Minimum required JARs (full client) *Build the single wlfullclient5.jar as described in the instructions for "Creating a wlfullclient5.jar for JDK 1.5 client applications."
Typical provider URL pattern

Thin Client:
iiop://yourhostnamehostname:7001

Full Client:
t3://yourhostnamehostname:7001

Factory class

JNDI Initial Context factory class:
- weblogic.jndi.WLInitialContextFactory

Learn morehttp://docs.oracle.com/cd/E12840_01/wls/docs103/client/jarbuilder.html

...

Scroll Table Layout
widths30%,70%

ForFor Progress Sonic MQ/ESB
Minimum required JARs

Found under <SONIC_INSTALL_DIR>/MQ7.x/lib:
- mfcontext.jar 
- broker.jar
- sonic_Client.jar

Note that SonicMQ's broker.jar and TIBCO’s tibcojms.jar cannot be used together.

Typical provider URL Pptterntcp://yourhostnamehostname:2506
Factory class

JNDI Initial Context factory class
- com.sonicsw.jndi.mfcontext.MFContextFactory

Learn moreRefer to SonicMQ Application Programming Guide, Appendix A (Using the Sonic JNDI SPI) and which also refers to other relevant sections.

...

Scroll Table Layout
widths30%,70%

ForFor RabbitMQ
Minimum required JARs

Download client library from Maven's Central Repository.

rabbitmq-jms-<version><VERSION>.jar

.bindings file example#This file is used by the JNDI FSContext.
#Wed Jan 31 15:36:15 PST 2018
ConnectionFactory/FactoryName=com.rabbitmq.jms.admin.RMQObjectFactory
ConnectionFactory/ClassName=javax.jms.ConnectionFactory
ConnectionFactory/RefAddr/0/Type=name
ConnectionFactory/RefAddr/0/Encoding=String
ConnectionFactory/RefAddr/0/Content=jms/ConnectionFactory
ConnectionFactory/RefAddr/1/Type=type
ConnectionFactory/RefAddr/1/Encoding=String
ConnectionFactory/RefAddr/1/Content=javax.jms.ConnectionFactory
ConnectionFactory/RefAddr/2/Type=factory
ConnectionFactory/RefAddr/2/Encoding=String
ConnectionFactory/RefAddr/2/Content=com.rabbitmq.jms.admin.RMQObjectFactory
ConnectionFactory/RefAddr/3/Type=host
ConnectionFactory/RefAddr/3/Encoding=String
ConnectionFactory/RefAddr/3/Content=host.company.com
ConnectionFactory/RefAddr/4/Type=port
ConnectionFactory/RefAddr/4/Encoding=String
ConnectionFactory/RefAddr/4/Content=5672
Typical provider URL pattern

The directory path containing the .bindings file

file://C:/JNDI/rabbitMQ/

Initial contextcom.sun.jndi.fscontext.RefFSContextFactory
Connection factory

JNDI Initial Context factory class
- ConnectionFactory

Solace JMS

Scroll Table Layout
widths30%,70%

ForFor Solace JMS
Minimum required JARscommons-lang-<version><VERSION>.jar
sol-common-<version><VERSION>.jar
sol-jcsmp-<version><VERSION>.jar
sol-jms-<version><VERSION>.jar
Typical provider URL patternsmf://<host><HOST>:<port><PORT>
Factory class

JNDI Initial Context factory class
 - com.solacesystems.jndi.SolJNDIInitialContextFactory
There is no default name; the specific JNDI name is needed to look up the connection factory.

The additional JNDI property  Solace_JMS_VPN=myvpn must be set in order to gain access to look up the connection factory. There is no default vpn name.

...

Scroll Table Layout
widths30%,70%

ForFor Sun MQ Server
Minimum required JARs

Found under <SUN_MQ_INSTALL_DIR>/Sun/MessageQueue/mq/lib:
- fscontext.jar
- imq.jar
- jms.jar

Typical provider URL patternyourhostnamehostname
Factory class

JNDI Initial Context factory class
- com.sun.jndi.fscontext.RefFSContextFactory

Learn moreSee the Sun Java System Message Queue Administration 3.x/4.x Guide, Section Quick-Start Tutorial. This document can be downloaded from http://docs.sun.com/app/docs/prod/message?l=en#hic. In the document, navigate to Software > Application & Integration Services > Message Queue.

...

Scroll Table Layout
widths30%,70%

ForFor TIBCO EMS
Minimum required JARs

Found under <TIBCO_INSTALL_DIR>/ems/clients/java:
- tibjms.jar
- tibcrypt.jar (required for SSL)

Note that SonicMQ's broker.jar and TIBCO’s tibcojms.jar cannot be used together.

Typical provider URL patterntcp://yourhostnamehostname:7222
yourhostname hostname (if using default port numbers)
Factory class

JNDI Initial Context factory class
- com.tibco.tibjms.naming.TibjmsInitialContextFactory

SSL configuration

The following JNDI properties must be configured:
- com.tibco.tibjms.naming.security_protocol=ssl
- com.tibco.tibjms.naming.ssl_enable_verify_host=false
- com.tibco.tibjms.naming.ssl_enable_verify_hostname=false

For two-way SSL, the following additional properties must also be configured:
 - com.tibco.tibjms.naming.ssl_identity=<path to client keystore><PATH_TO_CLIENT_KEYSTORE>
 - com.tibco.tibjms.naming.ssl_password=<keystore password><KEYSTORE_PASSWORD>
 - com.tibco.tibjms.naming.ssl_trusted_certs=<path to trusted certificate> 
<PATH_TO_TRUSTED_CERTIFICATE> 
 - com.tibco.tibjms.naming.ssl_vendor=j2se
 - com.tibco.tibjms.naming.ssl_auth_only=true/false

Additional information

Any time that a username and password is needed to connect to Tibco EMS the following JNDI properties must be configured:
 - java.naming.security.principal=<username>  <USERNAME> 
 - java.naming.security.credentials=<password><PASSWORD>

Learn moreRefer to the TIBCO Enterprise Message Service User's Guide, section 9: Developing an EMS Client Application> Application > Programmer Checklist


Anchor
Sun JMS
Sun JMS
Sun JMS

SOAtest and Virtualize bundle a Sun JNDI implementation that stores JNDI bindings in directories and files on the local hard drive using com.sun.jndi.fscontext.RefFSContextFactory as the Initial Context and a user defined Provider URL (directory) of “of C:\JNDIRoot” or  or something similar.

When using the Sun implementation, you must populate the “the C:\JNDIRoot” directory  directory with a .binding file so that fscontext can successfully look up the ConnectionFactory and Queue or Topic objects. Parasoft has put together an example that can be found in the SOAtest/Virtualize installation directory (/examples/jms/JndiFileProviderTest.java), which creates a .binding file.

...