Skip to content

zeelos/lwm2m-jmeter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

lwm2m-jmeter

(forked from vears91/lwm2m-jmeter original repo with small enchancements to allow compatibility with the latest jmeter library and enable customizable parameters during test invocation). Kudos to Victor Araujo for the initial plugin writing.

This project is a plugin for Apache JMeter that implements samplers and config elements for the LightweightM2m protocol. It allows JMeter threads to act as virtual LWM2M clients that can register, derregister and push observations to a LWM2M server.

This plugin can be used with JMeter to test non-functional and functional aspects of LWM2M servers. It uses lightweight mock LWM2M clients based on Californium to interact with the server. It has been tested with up to 2000 simultaneous clients generating load in a single commodity machine (a laptop with 8 GB RAM and an Intel Core i7-4710HQ CPU @ 2.50GHz processor), and more than 10,000 using JMeter's distributed mode in Amazon Web Services.

If you want to generate load without using JMeter or test simple use cases, you can use the mock client that is used in this plugin and write a scenario yourself. If you need a full-fledged LWM2M implementation, take a look at Eclipse Leshan.

Installation

As with all JMeter plugins, you should copy the jar file to the "lib/ext" directory in JMeter's installation.

  1. Clone this project with git clone https://github.com/vears91/lwm2m-jmeter.git
  2. Go the project directory and build it or install it with maven mvn install.
  3. After a successful build, go to the "target" directory and copy the generated jar-with-dependencies to JMeter's lib/ext directory cp ./target/lwm2m-jmeter-version-jar-with-dependencies.jar /path/jmeter/installation/lib/ext

When you open JMeter, you should be able to add the test elements of the plugin, like LWM2mConfig elements and NotifyObserverSampler.

Usage

You can check out some simple test plans in the doc/examples/ directory of this repository. The basic steps to get started are the following:

  1. Open JMeter
  2. Add a thread group
  3. Right click the thread group and choose Add/Config Element/LwM2mConfig
  4. Define the configuration of LWM2M clients in the LwM2mConfig element you added in the previous step. Here you will define the URI of the server to target, the available resources in each virtual client and registration options.
  5. Add samplers from the samplers submenu when right clicking a thread group and going to the Add/Sampler submenu.

About

LWM2M JMeter plugin.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages