I'm using JMeter 3.3 to load test MongoDB 3.4. Because I want to simulate 10k near-parallel users I'm using the distributed mode of JMeter on 35 VMs. In addition I follow many of the performance-tips for JMeter include starting it in non-gui-mode using no Listeners, increasing heap-size etc. When I add more slaves to the JMeter-Cluster I get better performance-results from MongoDB. So it is obvious that the bottleneck is still JMeter. But somehow I have a strange feeling because the 35 VMs have 8 cpu-cores each and 28 GB RAM. Some more facts on my setup:
JMeter Thread Group: 286 Threads, Ramp-Up Period 15 seconds, loop count forever, duration 300 (so in addition on 35 machines there will be 10010 threads stressing the MongoDB approximately 5 minutes).
I'm using the MongoDB Source Config. I know that it's deprecated but can't find an alternative... and a JSR223 Sampler with this groovy script:
import com.mongodb.*; import org.apache.jmeter.protocol.mongodb.config.MongoDBHolder import java.util.concurrent.ThreadLocalRandom; int randomNumber = ThreadLocalRandom.current().nextInt(1, 50000001); DB db = MongoDBHolder.getDBFromSource(„whatever“, „inka“); DBCollection collection = db.getCollection(„profiles“); BasicDBObject query = new BasicDBObject(„_id“, randomNumber); DBObject result = collection.findOne(query); SampleResult.setResponseData(result.toString().getBytes());
So finally my question: does it seem plausible to you that 35 VMs still aren't enough? I appreciate any thought!