tuanhiep / mqttjmeter Goto Github PK
View Code? Open in Web Editor NEWThis is the plugin for Jmeter to Test MQTT protocol
License: Apache License 2.0
This is the plugin for Jmeter to Test MQTT protocol
License: Apache License 2.0
I am using JDK 1.6, Maven 3.2.3.
Details:
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /home/lee/Opensource/mqtt-jmeter/src/main/java/org/apache/jmeter/protocol/mqtt/control/gui/MQTTPublisherGui.java:[138,19] type javax.swing.JComboBox does not take parameters
[ERROR] /home/lee/Opensource/mqtt-jmeter/src/main/java/org/apache/jmeter/protocol/mqtt/control/gui/MQTTPublisherGui.java:[138,57] type javax.swing.JComboBox does not take parameters
[INFO] 2 errors
Hallo @tuanhiep I would like to thank you very much for the effort taken to deliver this plugin. I would like to use it for performance measurements of diffrent MQTT brokers as the Jmeter is well known for me.
And here I have question/problem: I have get java.net.ConnectException: Connection refused. I have tried to remove obstackles as firewalls (iptables), hosts tables are also ok- mosquitto pub/sub is working just fine.
I am using as written by you in the doc tcp://localhost:1883 and all of the combinations possible of it -none of them work.
I have tried to compile both windows 7 and linux ubuntu lts 14.04
Best regards
Christopher
I am facing problems installing mqtt-jmeter plugin.
I have changed the contents of the message.properties file inside the resources folder of ApacheJMeter_core.jar file with the one inside mqtt-jmeter repo (as mentioned in the README file).
However, when I execute JMeter after making this change I get the following error:
java.lang.ClassNotFoundException: org.apache.jmeter.JMeter
at java.net.URLClassLoader$1.run(URLClassLoader.java:372)
at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:360)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at org.apache.jmeter.NewDriver.main(NewDriver.java:255)
If I undo the changes in message.properties and run again, JMeter runs without any errors.
Please help in setting up the plugin.
Hi,
i'm using the mqtt-jmeter plugin in order to perform stress tests, but can't access a user parameters which i defined in a pre-processor. do you have any idea why could it happen?
i'm using the publisher as described in the following process:
-- loop account
---- define account (pre-processor)
---- loop user
------ define user (pre-processor)
------ mqtt publisher (the topic is based on the account & user, the message also contains the account & user)
Refering to what's commented on issue #12:
"3) Subscriber : Keeps saying Received 0 messages thou there is something published."
Subscriptions are performed, but I cannot confirm they have received any topic or not, nor the time they received the topic.
Is there any solution to this problem already?
Thank you!
Hi,
In MQTT Publisher, the "Client ID" field is not able to retain or save any values. I enter a value in the Client ID field and if i click on any other component in the test plan and come back to the MQTT sampler, the value in the field disappears. Similarly, the "Random Suffix" check box is checked whenever the script is opened, whereas i want the checkbox to be unchecked always.
In the MQTT Subscriber, the Cient ID field is able to retain the value but the Random Suffix is checked everytime i open the script although i made sure it is unchecked and the script is saved.
Please tell me why this issue occurs and also it would be great if you could tell me the purpose of the Random suffix checkbox.
Thanks,
BK
I'm trying to make a MQTT test (pub/sub) but Jmeter gives me this Exception:
2015/05/29 11:21:33 ERROR - jmeter.threads.JMeterThread: Test failed! java.lang.NoClassDefFoundError: org/fusesource/mqtt/client/Callback
at org.apache.jmeter.protocol.mqtt.sampler.SubscriberSampler.threadStarted(SubscriberSampler.java:221)
at org.apache.jmeter.threads.JMeterThread$ThreadListenerTraverser.addNode(JMeterThread.java:610)
at org.apache.jorphan.collections.HashTree.traverseInto(HashTree.java:998)
at org.apache.jorphan.collections.HashTree.traverse(HashTree.java:980)
at org.apache.jmeter.threads.JMeterThread.threadStarted(JMeterThread.java:579)
at org.apache.jmeter.threads.JMeterThread.initRun(JMeterThread.java:567)
at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:257)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.ClassNotFoundException: org.fusesource.mqtt.client.Callback
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
... 8 more
2015/05/29 11:21:33 INFO - jmeter.threads.JMeterThread: Thread finished: Grupo de Usuários 1-1
2015/05/29 11:21:33 ERROR - jmeter.JMeter: Uncaught exception: java.lang.NoClassDefFoundError: org/fusesource/mqtt/client/Listener
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
at org.apache.jmeter.protocol.mqtt.sampler.SubscriberSampler.threadFinished(SubscriberSampler.java:282)
at org.apache.jmeter.threads.JMeterThread$ThreadListenerTraverser.addNode(JMeterThread.java:612)
at org.apache.jorphan.collections.HashTree.traverseInto(HashTree.java:998)
at org.apache.jorphan.collections.HashTree.traverse(HashTree.java:980)
at org.apache.jmeter.threads.JMeterThread.threadFinished(JMeterThread.java:584)
at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:315)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.ClassNotFoundException: org.fusesource.mqtt.client.Listener
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
... 18 more
2015/05/29 11:21:33 INFO - jmeter.engine.StandardJMeterEngine: Notifying test listeners of end of test
2015/05/29 11:21:33 ERROR - jmeter.JMeter: Uncaught exception: java.lang.NoClassDefFoundError: org/apache/jmeter/protocol/mqtt/client/ListenerforSubscribe
at org.apache.jmeter.protocol.mqtt.sampler.SubscriberSampler.testEnded(SubscriberSampler.java:179)
at org.apache.jmeter.engine.StandardJMeterEngine.notifyTestListenersOfEnd(StandardJMeterEngine.java:226)
at org.apache.jmeter.engine.StandardJMeterEngine.run(StandardJMeterEngine.java:448)
at java.lang.Thread.run(Thread.java:745)
I followed your installation instructions at README.
Hello,
I have recently started using MOTT- Jmeter jar by using the source code you shared at Git.hub.while utilizing this jar I have come accross below issues.
Could you look into this
Hi and congrats for the wonderful work so far.
Just wondering if wss support is on the roadmap.
Hi @tuanhiep i am trying the plugin step by step with installation process but i get this:
2015/04/16 16:39:35 ERROR - jmeter.threads.JMeterThread: Test failed! java.lang.NumberFormatException: For input string: ""
at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
at java.lang.Integer.parseInt(Integer.java:504)
at java.lang.Integer.parseInt(Integer.java:527)
at org.apache.jmeter.protocol.mqtt.client.MqttPublisher.setupTest(MqttPublisher.java:73)
at org.apache.jmeter.protocol.mqtt.sampler.PublisherSampler.threadStarted(PublisherSampler.java:419)
at org.apache.jmeter.threads.JMeterThread$ThreadListenerTraverser.addNode(JMeterThread.java:610)
at org.apache.jorphan.collections.HashTree.traverseInto(HashTree.java:998)
at org.apache.jorphan.collections.HashTree.traverse(HashTree.java:980)
at org.apache.jmeter.threads.JMeterThread.threadStarted(JMeterThread.java:579)
at org.apache.jmeter.threads.JMeterThread.initRun(JMeterThread.java:567)
at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:257)
at java.lang.Thread.run(Thread.java:745)
I did all the steps for installation, and i am trying to publish, what am i missing thanks
Any ideas? I thought the FutureConnection dependency would be compiled into the mqtt.jar that's built with mvn clean install package
But that does not appear to be the case.
Please help shed some light on this.
2015/05/07 14:37:25 INFO - jmeter.engine.StandardJMeterEngine: Running the test!
2015/05/07 14:37:25 INFO - jmeter.samplers.SampleEvent: List of sample_variables: []
2015/05/07 14:37:25 INFO - jmeter.gui.util.JMeterMenuBar: setRunning(true,*local*)
2015/05/07 14:37:25 INFO - jmeter.engine.StandardJMeterEngine: Starting ThreadGroup: 1 : Thread Group
2015/05/07 14:37:25 INFO - jmeter.engine.StandardJMeterEngine: Starting 1 threads for group Thread Group.
2015/05/07 14:37:25 INFO - jmeter.engine.StandardJMeterEngine: Thread will continue on error
2015/05/07 14:37:25 INFO - jmeter.threads.ThreadGroup: Starting thread group number 1 threads 1 ramp-up 1 perThread 1000.0 delayedStart=false
2015/05/07 14:37:25 INFO - jmeter.threads.ThreadGroup: Started thread group number 1
2015/05/07 14:37:25 INFO - jmeter.engine.StandardJMeterEngine: All thread groups have been started
2015/05/07 14:37:25 INFO - jmeter.threads.JMeterThread: Thread started: Thread Group 1-1
2015/05/07 14:37:25 ERROR - jmeter.threads.JMeterThread: Test failed! java.lang.NoClassDefFoundError: org/fusesource/mqtt/client/FutureConnection
at org.apache.jmeter.protocol.mqtt.client.MqttPublisher.setupTest(MqttPublisher.java:98)
at org.apache.jmeter.protocol.mqtt.client.MqttPublisher.setupTest(MqttPublisher.java:79)
at org.apache.jmeter.protocol.mqtt.sampler.PublisherSampler.threadStarted(PublisherSampler.java:419)
at org.apache.jmeter.threads.JMeterThread$ThreadListenerTraverser.addNode(JMeterThread.java:610)
at org.apache.jorphan.collections.HashTree.traverseInto(HashTree.java:998)
at org.apache.jorphan.collections.HashTree.traverse(HashTree.java:980)
at org.apache.jmeter.threads.JMeterThread.threadStarted(JMeterThread.java:579)
at org.apache.jmeter.threads.JMeterThread.initRun(JMeterThread.java:567)
at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:257)
at java.lang.Thread.run(Thread.java:745)
2015/05/07 14:37:25 INFO - jmeter.threads.JMeterThread: Thread finished: Thread Group 1-1
2015/05/07 14:37:25 INFO - jmeter.engine.StandardJMeterEngine: Notifying test listeners of end of test
2015/05/07 14:37:25 INFO - jmeter.gui.util.JMeterMenuBar: setRunning(false,*local*)
Hi,
In MQTT Publisher, the "Random Suffix" check box is checked whenever the script is opened, whereas i want the checkbox to be unchecked always.
In the MQTT Subscriber, the Cient ID field is able to retain the value but the Random Suffix is checked everytime i open the script although i made sure it is unchecked and the script is saved.
Please tell me why this issue occurs and also it would be great if you could tell me the purpose of the Random suffix checkbox.
Thanks,
Swapnil
If the plugin support the ssl connection, it would be perfect. In addition, when I copy the jmeter-mqtt.jar to ext/lib. It doesn't work, I still need to copy mqtt-client.jar from fugesource.
When trying to change the message Content and mqtt-topic, on a per thread basis, using a CSV Data set does not result in substitution of the variables
For example, given the message:
Thread = ${__threadNum()} - var = ${HELLO} - cvs = ${ITEM}
the mutt sampler will correctly substitute the Thread number, the user variable 'HELLO', but not the CSV 'ITEM' variable .
Is variable substitution with CSV data sets supported by the component ?
After successfully installing the plugin, I've configured both a Publisher and Subscriber samplers. Running both samplers does nothing.... not getting any response / error.
Any advice?
I'm getting the following error when I try to make an MQTT test (either pub or sub):
2015/06/13 14:26:27 ERROR - jmeter.protocol.java.sampler.AbstractJavaSamplerClient:
And when I stop the simulation the following error message is shown in the log:
2015/06/13 14:29:17 ERROR - jmeter.JMeter: Uncaught exception: java.lang.NullPointerException
at org.fusesource.mqtt.client.CallbackConnection$8.onSuccess(CallbackConnection.java:506)
at org.fusesource.mqtt.client.CallbackConnection$8.onSuccess(CallbackConnection.java:495)
at org.fusesource.mqtt.client.CallbackConnection.disconnect(CallbackConnection.java:519)
at org.fusesource.mqtt.client.FutureConnection$3.run(FutureConnection.java:104)
at org.fusesource.hawtdispatch.internal.SerialDispatchQueue.run(SerialDispatchQueue.java:96)
at org.fusesource.hawtdispatch.internal.pool.SimpleThread.run(SimpleThread.java:77)
Here's a screenshot of the parameters I'm using in Jmeter: https://dl.dropboxusercontent.com/u/546167/jmeter-mqtt-error.PNG
I got a exception as this:
2015/01/20 14:18:24 ERROR - jmeter.threads.JMeterThread: Test failed! java.lang.NoClassDefFoundError: org/fusesource/mqtt/client/FutureConnection
at org.apache.jmeter.protocol.mqtt.client.MqttPublisher.setupTest(MqttPublisher.java:98)
at org.apache.jmeter.protocol.mqtt.client.MqttPublisher.setupTest(MqttPublisher.java:79)
at org.apache.jmeter.protocol.mqtt.sampler.PublisherSampler.threadStarted(PublisherSampler.java:419)
at org.apache.jmeter.threads.JMeterThread$ThreadListenerTraverser.addNode(JMeterThread.java:599)
at org.apache.jorphan.collections.HashTree.traverseInto(HashTree.java:961)
at org.apache.jorphan.collections.HashTree.traverse(HashTree.java:946)
at org.apache.jmeter.threads.JMeterThread.threadStarted(JMeterThread.java:568)
at org.apache.jmeter.threads.JMeterThread.initRun(JMeterThread.java:556)
at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:254)
at java.lang.Thread.run(Unknown Source)
I have downloaded the code, created a jar file and placed it in lib folder of jmeter. The publishing works fine but instead of column names i can see the column names as res_key=mqtt_subscriber_title. This is true for all column/field names.i have followed the steps mentioned like updating the message.properties file in ApacheJmeter_core.jar file. Please help.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.