Defining number of threads as a JMeter property #260
-
Hi. First of all thank you for this awesome library! I haven't found in docs if there is a way to define the number of threads or iterations as a JMeter property like Best regards, |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Hello, thank your for the feedback, is really nice to hear from people enjoying the library. In the user guide we didn't include such specific scenario, but yes, you can use them. You can define properties as detailed in this user guide section, and then reference them like this: Eg: threadGroup()
.rampTo("${__P(THREADS)}", Duration.Zero)
.holdIterating("${__P(ITERATIONS)}")
.children(
...
) We didn't include yet an option like Is this enough for your use case? |
Beta Was this translation helpful? Give feedback.
-
This is what I put in the property file:
Thread group:
Error: Can someone pls advice what is wrong here? |
Beta Was this translation helpful? Give feedback.
Hello, thank your for the feedback, is really nice to hear from people enjoying the library.
In the user guide we didn't include such specific scenario, but yes, you can use them.
You can define properties as detailed in this user guide section, and then reference them like this:
Eg:
We didn't include yet an option like
threadGroup("${__P(THREADS)}", "${__P(ITERATIONS)}")
since the scenario is not the most common one (from the ones we have seen) and only add to JMeterDSL class, methods for the most used scenarios (keeping the list as short as possible short, but yet i…