Search code examples
activemq-artemis

ActiveMQ Artemis JMS Provider Class-Path configuration


I have updated ActiveMQ Artemis to address vulnerabilities, and it is currently running on version 2.31.2. We have specified the JMS provider for connecting to ActiveMQ Artemis from WebSphere:

enter image description here

My doubt is whether the classpath I have provided for a few JAR files is suitable for ActiveMQ Artemis 2.31.2. Is it fine, or do I need to use any extra JAR files? Additionally, will ActiveMQ Artemis 2.31.2 support these JAR versions?

Currently we are providing:

  • activemq-client-5.14.5.jar
  • hawbuf-1.11.jar
  • slf4j-api-1.7.13.jar

Solution

  • It appears you're using the OpenWire JMS client implementation from ActiveMQ Classic 5.14.5 (which is quite old). According to the Maven dependencies for the activemq-client module you've covered everything you need to:

        <!-- =============================== -->
        <!-- Required Dependencies -->
        <!-- =============================== -->
        <dependency>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-api</artifactId>
        </dependency>
        <dependency>
          <groupId>org.apache.geronimo.specs</groupId>
          <artifactId>geronimo-jms_1.1_spec</artifactId>
        </dependency>
        <dependency>
          <groupId>org.fusesource.hawtbuf</groupId>
          <artifactId>hawtbuf</artifactId>
          <version>${hawtbuf-version}</version>
        </dependency>
    

    To be clear, you don't need to include the JMS specification jar file because that's already provided implicitly by WebSphere.

    Keep in mind that you could upgrade the OpenWire JMS client to something newer (e.g. 5.18.3) or you could even switch to the core JMS client that ships with ActiveMQ Artemis, but that would require changing the context factory and the URL.