Hello,
I am using Artemis version 2.28.0 with OpenLiberty (via JCA/Resource Adapter) 
and have a few questions about the changes I had to make to the ra.xml.

I built the RA using the instructions in the Artemis documentation for the 
jakarta namespace:
https://activemq.apache.org/components/artemis/documentation/latest/resource-adapter.html

I ended up having had to make modifications to the ra.xml to get things to work 
(see below).

My understanding is that the ra.xml should have a configuration that links the 
interface (jakarta.jms.ConnectionFactory) with the impl.
In the original xml below, the connnectionfactory-interface, and the 
connection-interface elements both seem incorrect.
OpenLiberty wasn't able to look up the Artemis Connection factory using the 
original xml and would not have been able to ask about the Connection.
I reviewed the Artemis ra source and made changes to the xml as shown below.
After making these changes, OpenLiberty was able to connect and interact with 
Artemis.

Original xml:
<outbound-resourceadapter>
         <connection-definition>
           
<connectionfactory-interface>org.apache.activemq.artemis.ra.ActiveMQRAConnectionFactory</connectionfactory-interface>
            
<connectionfactory-impl-class>org.apache.activemq.artemis.ra.ActiveMQRAConnectionFactoryImpl</connectionfactory-impl-class>
            <connection-interface>jakarta.jms.Session</connection-interface>
            
<connection-impl-class>org.apache.activemq.artemis.ra.ActiveMQRASession</connection-impl-class>
         </connection-definition>
      </outbound-resourceadapter>

Changed to xml:
<outbound-resourceadapter>
         <connection-definition>
            
<connectionfactory-interface>jakarta.jms.ConnectionFactory</connectionfactory-interface>
            
<connectionfactory-impl-class>org.apache.activemq.artemis.ra.ActiveMQRAConnectionFactoryImpl</connectionfactory-impl-class>
            <connection-interface>jakarta.jms.Connection</connection-interface>
            
<connection-impl-class>org.apache.activemq.artemis.ra.ActiveMQRASessionFactoryImpl</connection-impl-class>
         </connection-definition>
      </outbound-resourceadapter>


Here are my Questions:

  1.  Am I going about this the right way??
  2.  Has anyone else used Artemis as a JCA?
     *   If so, did you have to make these changes or how did you get this to 
work?
  3.  Is the ra.xml configuration a bug/defect?
  4.  Will this be changed/corrected in a future release?
  5.  Are my changes correct?
     *   It seems to be working but I would like to get some oversight to feel 
more confident.

Thanks in advance.

-Tom





Reply via email to