Skip to content

Improve scalability in common cases - #5920

Closed
vlsi wants to merge 0 commit into
apache:masterfrom
vlsi:scalability
Closed

Improve scalability in common cases#5920
vlsi wants to merge 0 commit into
apache:masterfrom
vlsi:scalability

Conversation

@vlsi

@vlsi vlsi commented May 17, 2023

Copy link
Copy Markdown
Collaborator

Description

This is a set of fixes that address common synchronization issues in JMeter.

Motivation and Context

It would be nice if JMeter could generate high number of concurrent requests without blocking in cases like

  • iterating over TestBean properties
  • retrieving ThreadGroup.getName() -> syncrhonized propMap.get("...")
  • aggregating results into TOTAL row, so synchronizing on the counters

Benchmarks

See benchmark in #5875 (comment)

Rampup 0 (e.g. to make all the threads produce load faster)
Java 17.0.17
Apple M1 Max (2 efficiency and 8 performance cores)
Apparently, 100 threads doing CPU-intensive tasks makes no sense for 10 core machine, but it improved as well.
Notable improvement comes when a thread acquires a synchrinization lock and it gets preempted from the execution. When that happens, the other threads can't proceed until the thread moves to CPU again.
It means even short-lived synchronized sections are harmful.

The PR makes many such cases impossible.

Title100 threads4 threads2 threads1 threads
Before1M/sec1.3M/sec1.2M/sec1.1M/sec
After3M/sec2.1M/sec1.5M/sec1.3M/sec

@vlsi
vlsi force-pushed the scalability branch 4 times, most recently from 7fc279d to fafb948 Compare May 17, 2023 12:40
Comment thread src/core/src/main/java/org/apache/jmeter/util/Calculator.java Outdated
@vlsi
vlsi force-pushed the scalability branch 4 times, most recently from 2fdad4b to beacd35 Compare May 17, 2023 15:08
@vlsi vlsi added this to the 5.6 milestone May 17, 2023
@vlsi
vlsi force-pushed the scalability branch 5 times, most recently from 9e48147 to 012a5fc Compare May 18, 2023 14:45
@vlsi vlsi closed this May 19, 2023
@vlsi

vlsi commented May 19, 2023

Copy link
Copy Markdown
Collaborator Author

vlsi added a commit that referenced this pull request May 25, 2023
… as it was doing in 5.5

In fact, ThreadGroup elements are cloned for each thread, so they might need
recoverRunningVersion.

See #5920
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant