ActiveMQ

From Resin 3.0

(Difference between revisions)
Jump to: navigation, search
(New page: ActiveMQ can be configured in Resin using ActiveMQ's JCA adapter. The .rar file is in apache-activemq-5.0.0/lib/options/activemq-rar-5.0.0.rar In the resin.conf, you'll need to add a <re...)
 
Line 21: Line 21:
 
         </init>
 
         </init>
 
      
 
      
          <connection-factory class="javax.jms.QueueConnectionFactory"/>
+
        <connection-factory class="javax.jms.QueueConnectionFactory"/>
 
   
 
   
          <bean class="javax.jms.Queue">
+
        <bean class="javax.jms.Queue">
              <init PhysicalName="queue.test"/>
+
            <init PhysicalName="queue.test"/>
            </bean>
+
        </bean>
 
     </connector>
 
     </connector>
 
   </web-app>
 
   </web-app>
 +
 +
* The <connector> configures a JCA connector. 
 +
* The connector class is the resource adapter class. 
 +
* The <init> block configures the resource adapter parameters.
 +
* The <connection-factory> configures the outbound factory
 +
* The <bean> configures the Queue (i.e. the adminobject)

Revision as of 02:49, 17 December 2007

ActiveMQ can be configured in Resin using ActiveMQ's JCA adapter. The .rar file is in apache-activemq-5.0.0/lib/options/activemq-rar-5.0.0.rar

In the resin.conf, you'll need to add a <resource-deploy> tag to tell Resin where to look for resources:

 <resin xmlns="http://caucho.com/ns/resin">
   <cluster id="">
       <host id="">
          <resource-deploy path="deploy"/>
           ...
        </host>
    </cluster>
 </resin>

Then, in your resin-web.xml, you'll need to configure the connector. It will look like:

 <web-app xmlns="http://caucho.com/ns/resin">
   
    <connector class="org.apache.activemq.ra.ActiveMQResourceAdapter">
        <init>
            <ServerUrl>vm://localhost</ServerUrl>
        </init>
    
        <connection-factory class="javax.jms.QueueConnectionFactory"/>

        <bean class="javax.jms.Queue">
            <init PhysicalName="queue.test"/>
        </bean>
   </connector>
 </web-app>
  • The <connector> configures a JCA connector.
  • The connector class is the resource adapter class.
  • The <init> block configures the resource adapter parameters.
  • The <connection-factory> configures the outbound factory
  • The <bean> configures the Queue (i.e. the adminobject)
Personal tools