Technical Design for Apache OFBiz load testing with Apache JMeter

In our recent blog post OFBiz Performance Tip: sync vs async, we shared details outlining how two different OFBiz instances could be used to successfully process heavy loads generated in our load testing sessions. In that blog we shared how the load generated by synchronous and asynchronous services can be split and processed by the two OFBiz instances. In this post, we take it a step further to discuss technical design for Apache OFBiz load testing with Apache JMeter.

Below, we share two technical design options for Apache OFBiz load testing with Apache JMeter.

Design 1 – Master-Slave Design

The diagram below features a JMeter master-slave setup design used for load testing Apache OFBiz. To increase the load on the targeted OFBiz server any number of slave nodes can be added to the master system. More detailed information from the JMeter folks can be found here. This configuration is recommended when you want to generate a heavy load on the targeted server and the slave nodes have less RAM and a low speed processor.

JMeter OFBiz Architecture

Design 2: Single Machine Single User and Single Machine Multiple User

In this setup, there are two main combinations that can be used:

  1. Single Machine Single User: If the machine configuration is average then we can add a single user to every single machine and perform load testing. Machines of this type  can be connected in parallel for the desired amount of load.
  2. Single Machine Multiple User: If the machine configuration is high then we can create multiple user on that machine. The user name can be kept as user1 , user2, user3 … and so on. Each user will have a separate JMeter and jdk setup available for its use. For example, say we have 16GB RAM available with a high configuration machine and we want to setup two users on that machine. We can assign 6GB RAM to the JMeter setup of user1 and 6GB RAM to the JMeter setup of user2, and the remaining 3GB RAM will be used by the operating system.

JMeter OFBiz Architecture-HotWax Media

The hardware configuration details for all the servers involved in design two are shown below:

1) OFBiz01 Server: This server will be responsible for managing all the synchronous jobs.


2) OFBiz02 Server: This server will be responsible for managing all the asynchronous jobs.


3) Apache Server: All the requests will come to this server, and they will be transferred to OFBiz01 server where ofbiz instance is running.


4) Database Server:


The following configuration changes need to be done in my.cnf file:

slow_query_log = 1
log_slow_queries = 1
long_query_time = 3
log_output = TABLE
expire_logs_days = 2
innodb_buffer_pool_size = 10G
innodb_lock_wait_timeout = 300
innodb_file_per_table = 1

5) Jmeter Server:


Running the scripts

Once we have the required hardware configuration, we run JMeter scripts with large number of threads spread equally across two or more different users on the same machine.

We have worked with both designs and found that Design 2 is the better option for the load testing on the Amazon cloud.

Thanks for your time!

DATE: Aug 26, 2014
AUTHOR: Ashish Vijaywargiya
quality assurance, amazon clouds, OFBiz Tutorials, Load Testing, hotwax media, Apache OFBiz, apache jmeter, mysql, OFBiz, stress testing, Education