3 Replies Latest reply on Dec 22, 2009 1:27 PM by peterj

    JBoss Messaging with JMeter

      I am trying load test JBoss Messaging 1.4.3.GA integrated in Jboss 5.1.0.GA with JMeter. I have added JMS Publisher and Subscribers samplers in JMeter with following configuration.

       

      Initial Context Factory : org.jnp.interfaces.NamingContextFactory
      Provider URL : jnp://localhost:1099
      Connection Factory : ConnectionFactory

      Topic : "/topic/test_appln_data"

       

      I am getting following error for Publisher as well as Subscriber :-

      2009/12/21 19:12:45 INFO  - jmeter.threads.JMeterThread: Thread Publisher Thread Group 1-1 started
      2009/12/21 19:12:45 INFO  - jmeter.threads.JMeterThread: Thread  Subscribers - Thread Group 2-1 started
      2009/12/21 19:12:45 INFO  - jmeter.protocol.jms.client.InitialContextFactory: created the JNDI initial context factory
      2009/12/21 19:12:45 ERROR - jmeter.threads.JMeterThread:  java.lang.NullPointerException
              at org.apache.jmeter.protocol.jms.client.Publisher.initConnection(Publisher.java:86)
              at org.apache.jmeter.protocol.jms.client.Publisher.<init>(Publisher.java:63)
              at org.apache.jmeter.protocol.jms.sampler.PublisherSampler.initClient(PublisherSampler.java:110)
              at org.apache.jmeter.protocol.jms.sampler.PublisherSampler.sample(PublisherSampler.java:134)
              at org.apache.jmeter.protocol.jms.sampler.PublisherSampler.sample(PublisherSampler.java:121)
              at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:247)
              at java.lang.Thread.run(Thread.java:619)

       

      2009/12/21 19:12:45 ERROR - jmeter.threads.JMeterThread:  java.lang.NullPointerException
              at org.apache.jmeter.protocol.jms.client.ReceiveSubscriber.initConnection(ReceiveSubscriber.java:117)
              at org.apache.jmeter.protocol.jms.client.ReceiveSubscriber.<init>(ReceiveSubscriber.java:76)
              at org.apache.jmeter.protocol.jms.sampler.SubscriberSampler.initReceiveClient(SubscriberSampler.java:124)
              at org.apache.jmeter.protocol.jms.sampler.SubscriberSampler.sampleWithReceive(SubscriberSampler.java:201)
              at org.apache.jmeter.protocol.jms.sampler.SubscriberSampler.sample(SubscriberSampler.java:149)
              at org.apache.jmeter.protocol.jms.sampler.SubscriberSampler.sample(SubscriberSampler.java:138)
              at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:247)
              at java.lang.Thread.run(Thread.java:619)

       

       

      I have added following jars in jmeter/lib directory:-

      jboss-logging-jdk.jar
      jboss-logging-log4j.jar
      jboss-logging-spi.jar
      jboss-logmanager.jar
      jboss-messaging-client.jar
      jboss-messaging-int.jar

      jnp-client.jar

       

      I am not able to figure out the cause. Is there any documentation available for load testing with JMeter ?

        • 1. Re: JBoss Messaging with JMeter
          gaohoward

          I think you need to check (using jmx console) that the JMS connection factory and the topic are deployed and their JNDI names match your JMeter configuration.

           

          Howard

          • 2. Re: JBoss Messaging with JMeter
            I am already using the deployed jms topic in my application. So it is working fine from the application. I am able to put message and subscribe to the published message from the app. So the issue is related to JMeter interacting with JBoss Messagaing server.
            • 3. Re: JBoss Messaging with JMeter
              peterj

              Did you edit the jmeter.properties (or preferrably the user.properties) file and add the jbossall-client.jar file to the user.classpath setting?

               

              Also, exactly what version of JMeter are you using? Line 86 in the Publisher.java I have could not yield an NPE.  By the way, I recommend getting the very latest JMeter when using JMS - there was a significant bug due to some very poorly written initialization code.