Skip to content

Conversation

venkatesht678
Copy link
Contributor

Added auto-stop feature based on percentile value for response time.
Considering micro-services, this feature is helpful for latency sensitive application's where P95 and P99 are used to determine SLA breeches and stop the load automatically with the help of this plugin

@Override
public void sampleOccurred(SampleEvent se) {
SampleResult sr = se.getResult();
statCalc.addSample(sr);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be resource consuming, from what I remember. Please enclose it into if(testValuePercentileRespTime > 0) {}, so it's only called when actually used.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the suggestion. Have moved it under if(testValuePercentileRespTime > 0) {}

</Constraint>
</Constraints>
</Component>
<Component class="javax.swing.JLabel" name="jLabel13">
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please attach to PR the screenshot of resulting UI, to review the visual

log.debug(testPercentileValue+"Percentile Response >"+testValuePercentileRespTime+"until"+testValuePercentileRespTimeSec+"currentValue"+percentileResponseTime);
log.debug(testActualValue+">>"+testExpectedValue+">>"+skipIter+">>"+testValueCustomSec);
if(percentileResponseTime > testValuePercentileRespTime) {
log.dubeg((sec - percentileRespTimeExceededStart)+" "+getPercentileResponseTimeSecsAsInt());
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dubeg?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo. Have corrected and commented out. Thanks for the correction

}
}

if(testValuePercentileRespTime > 0) {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This whole block of code is not formatted well

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also excessive calls with concatenation will cost a lot of memory and CPU for JMeter

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have formatted and commented out debug statements

@undera undera merged commit 9cf9f05 into undera:master Jun 15, 2025
1 check passed
@undera
Copy link
Owner

undera commented Jun 15, 2025

Cool.
Please proceed to create new version in plugin descriptor. I will publish the build to maven now.

@venkatesht678
Copy link
Contributor Author

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants