This section describes Java Message Service (JMS) considerations for the JRun administrator. It includes descriptions of using the default JRun JMS provider, using the SonicMQ JMS implementation in place of the default JRun JMS provider, and how to configure factories and destinations.
The choice of JMS provider is controlled by settings in the jrun.xml file. In this file you indicate whether to use the JRun default JMS provider or a third-party JMS provider, such as SonicMQ. The jrun.xml file use the following services to define a JMS provider:
To modify the JMSAdapter and JMSServiceWrapper services, modify the jrun.xml file with a text editor.
Note: In addition to using the JMS resources and examples in this book, you can get additional information on JMS administration and programming by consulting a trade press book that discusses JMS. The preface of this book includes a list of these books.
In addition to settings made in the jrun.xml file and the JMC, you use the SERVER-INF/jrun-jms.xml file to control the behavior of the JRun default JMS provider. Use a text editor to modify the jrun-jms.xml file; you do not use the JMC.
The jrun-jms.xml file has persistence settings and server settings.
The default JMS provider supports the following persistence managers:
The jrun-jms.xml file's active-adapter-type element specifies the persistence type: file or rdbm. Optionally, you can control whether the JMS provider caches messages by using the cache element. Additionally, you can use the transact element to specify whether the DBMS provider uses transactionality. Other than these elements, you do not typically change elements in the jrun-jms.xml file.
The jrun-jms.xml file also includes the following elements:
JRun lets you use third-party JMS providers in place of the JMS provider supplied as part of JRun. You can switch JMS providers by editing relevant sections of a JRun server's jrun.xml file.
Note: JRun has been verified using version 3.5 of SonicMQ. Other versions of SonicMQ are currently not supported and SonicMQ 3.5 is the only third party JMS provider currently supported by JRun 4.0.
This section explains the steps involved in using the Progess Software SonicMQ JMS implementation in place of the JMS provider built in to JRun.
When configured to use SonicMQ as its JMS provider, JRun will automatically start a dedicated instance of SonicMQ with which it will interact. The only requirement is that the dedicated instance use a port that does not conflict with any other SonicMQ instances running on the same host.
To install SonicMQ, follow the steps in the SonicMQ installation documentation. No special installation configuration of SonicMQ is required to support its use with JRun.
To configure JRun to use SonicMQ, use a text editor to change the JRun server's jrun.xml file to use the SonicMQ adapter and service wrapper instead of the built in JRun adapter and service wrapper. The default jrun.xml file includes commented-out examples of appropriate settings for the SonicMQ adapter and wrapper. You also make server specific settings for SonicMQ.
<service class="jrun.jms.adapter.JRunMQAdapter" name="JMSAdapter"> and comment it out.
<service class="jrun.jms.wrapper.JRunMQServiceWrapper" name="JMSServiceWrapper"> and comment it out.
JMSAdapter and JMSServiceWrapper sections for the SonicMQ adapter and uncomment them so they are active. These sections begin with the following lines <service class="jrun.jms.adapter.SonicMQAdapter" name="JMSAdapter"> and <service class="jrun.jms.wrapper.SonicMQServiceWrapper" name="JMSServiceWrapper">.
jrun.jms.adapter.SonicMQAdapter section, edit the following attributes to reflect your local SonicMQ installation:
JAR files found in this directory are automatically added to the classpath of any running JRun servers.
transport attribute for JMS connection factories in the jrun-resources.xml file is set to TCPIP. The only transport type supported with SonicMQ is TCP/IP. JRun manages the following types of JMS factories and destinations:
JMS connection factories allow clients (both senders and receivers) to establish a connection with JMS. The client accesses the connection factory with a JNDI lookup and uses the factory to create a connection. Clients also access destinations (that is, queues and topics) through JNDI.
You typically use the JMC to define factories, destinations, and their location in JNDI. JRun stores factory and destination information in the jrun-resources.xml file, which you can also edit manually. For more information on the jrun-resources.xml file, see "Resources: the jrun-resources.xml file" or the online descriptor documentation, available from the JRun documentation home page.
For more information on factories and destinations, see the JMC online help.
Send me an e-mail when comments are added to this page | Comment Report
Current page: http://livedocs.adobe.com/jrun/4/JRun_Administrators_Guide/resources3.htm