-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Listening for Errors and Throughput to Dynamically Stop the Test #287
Comments
Have you try adding autostop to the loaded test plan? |
Yes in the loaded .JMX file there is @ AutoStop Listener but it check on the error rate only and I need to check also the Throughput while running |
The autostop element currently allows to check conditions on connectionTime, sampleTime, latencyTime, errors, samples, received and sent bytes. For times you can check max, mean, min and percentiles and for the rest you can check perSecond and total, all being able to specify a period of evaluation and checking with different comparators. For throughput for example you can use samples and perSecond, or samples total and then specify a period of time for evaluation (for example if you want to measure per minute, hour, etc). You can check all available methods and options using any IDE. |
yes , this is if iam building the test plan form the beginning using the jmtereDSL , but what if iam loading an existing jmxfile that was already created by Jmeter GUI Previously which have JMeter AutoStop Plugin that just check on response time and error rate. |
yes. Modifying existing autostop would be treaky, but you can add a new one as the example you gave. |
oki , so how I can add a new one ? you mean to make a custom element like [wrapper]https://abstracta.github.io/jmeter-java-dsl/guide/#custom-or-yet-not-supported-test-elements or there is any other way you mean ? |
No, you can use like the plan you pasted and if you want add more when
method invocations in the same chain
…On Thu, Dec 5, 2024, 19:02 Farahala ***@***.***> wrote:
oki , so how I can add a new one ? you mean to make a custom element like
[wrapper]
https://abstracta.github.io/jmeter-java-dsl/guide/#custom-or-yet-not-supported-test-elements
or there is any other way you mean ?
—
Reply to this email directly, view it on GitHub
<#287 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAYIFL46EPGL6MJ7P7GP7732EDEOZAVCNFSM6AAAAABTC5DSUWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKMRRGU2TSNJYHA>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
First, thank you for your response and support. Let me try to break down the issue I'm encountering. When I tried using autoStop() like this: DslTestPlan testPlan = DslTestPlan.fromJmx("filepath");
I also tried this:
So my question is: Thanks again for your continued support! |
Have you tried using children method in loaded test plan?
…On Fri, Dec 6, 2024, 16:22 Farahala ***@***.***> wrote:
First, thank you for your response and support. Let me try to break down
the issue I'm encountering.
When I tried using autoStop() like this:
*DslTestPlan testPlan = DslTestPlan.fromJmx("filepath");
autoStop().when(errors().percent().greaterThan(10.0)); testPlan.run();*
1. It doesn't work because the problem lies in the order of operations
and how the autoStop configuration is applied. I am calling autoStop()
after building the DslTestPlan and before running the test, which is not
correct. If I understand correctly, autoStop needs to be integrated during
the build process.
I also tried this:
*DslTestPlan testPlan = new DslTestPlan( fromJmx("filepath"), autoStop()
.when(errors().percent().greaterThan(10.0)) ).run();*
2. This also doesn't work because the issue lies in passing autoStop()
and other elements as arguments to the DslTestPlan constructor, which is
incorrect. The DslTestPlan constructor expects a list of TestPlanChild
elements (e.g., thread groups, controllers), not a TestPlanStats object
(returned by .run()) or the autoStop configuration directly.
So my question is:
Is there a way to use autoStop() with DslTestPlan.fromJmx()? What is the
correct order or structure to achieve this?
Thanks again for your continued support!
—
Reply to this email directly, view it on GitHub
<#287 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAYIFL5UZZX5R5N5DUWVTT32EH2Q3AVCNFSM6AAAAABTC5DSUWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKMRTHE4TSNRQGM>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Yes , I got it , it works now with children method thanks , this will check as aggerate , is there is a way to check on each sampler or this will need to be customized ? |
You can filter by sampler name in auto stop conditions if you want to check each sampler stats. |
oki , got it , thanks alot |
loading the jmx by using DslTestPlan testPlan = DslTestPlan.fromJmx(jmxFilePath);
is there is way to listen on error and throughput while running the script to check once the run start if the throughput or error rate from the beginning is high then stop the test and terminate .
I need to check that while the script is running not after it finished and then check the results .
The text was updated successfully, but these errors were encountered: