Skip to content
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

Enhancements to support queue with AIMD and new metrics #9605

Draft
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

spericas
Copy link
Member

@spericas spericas commented Dec 18, 2024

Description

Enhancements to support queue with AIMD and new metrics. Issue #9542 and #9304.

Documentation

In a follow-up PR

@spericas spericas added enhancement New feature or request webserver 4.x Version 4.x labels Dec 18, 2024
@spericas spericas added this to the 4.2.0 milestone Dec 18, 2024
@spericas spericas self-assigned this Dec 18, 2024
@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label Dec 18, 2024
@spericas spericas marked this pull request as draft December 18, 2024 15:30
@spericas spericas force-pushed the issue-9542 branch 2 times, most recently from 9a1909b to 443d251 Compare January 3, 2025 16:42
@spericas spericas force-pushed the issue-9542 branch 2 times, most recently from 014ed21 to 45dd1d8 Compare January 17, 2025 13:40
@VishalSharma-123
Copy link

VishalSharma-123 commented Jan 21, 2025

Hi @spericas.
While conducting the tests, I found out that the data for number of concurrent requests and for RTT Time was not being recorded properly. It remained at a constant value of 0.0 even under a load of very high user. Upon debugging the code, the invoke() method which contains the code for recording the data, was never called. Hence the data was not being recorded.

For it's fix, I tried to create a private class called FixedToken in FixedLimit.java, having a similar implementation as the AIMDToken in AIMDLimitImpl.java, and passing this class in the QueueSemaphore constructor for creating the handler. The required data for number of concurrent requests and for RTT Time is being recorded in FixedToken.

With this fix, the metric data for number of concurrent requests and for RTT Time is being recorded properly now.

Output Before the Fix
default_fixed_concurrent_requests{mp_scope="vendor",} 0.0 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.5",} 0.0 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.75",} 0.0 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.95",} 0.0 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.98",} 0.0 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.99",} 0.0 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.999",} 0.0 default_fixed_queue_wait_time_seconds_count{mp_scope="vendor",} 0.0 default_fixed_queue_wait_time_seconds_sum{mp_scope="vendor",} 0.0

Output After the Fix
default_fixed_concurrent_requests{mp_scope="vendor",} 51.0 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.5",} 0.452722688 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.75",} 0.704380928 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.95",} 1.140588544 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.98",} 1.409024 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.99",} 1.543241728 default_fixed_queue_wait_time_seconds{mp_scope="vendor",quantile="0.999",} 2.281439232 default_fixed_queue_wait_time_seconds_count{mp_scope="vendor",} 10547.0 default_fixed_queue_wait_time_seconds_sum{mp_scope="vendor",} 5652.533172794

I have also attached a zip that contains the new FixedLimit.java and a Difference.txt to highlight the changes.

Changes for Fixed Limit.zip

Signed-off-by: Santiago Pericas-Geertsen <[email protected]>
Signed-off-by: Santiago Pericas-Geertsen <[email protected]>
Signed-off-by: Santiago Pericas-Geertsen <[email protected]>
Signed-off-by: Santiago Pericas-Geertsen <[email protected]>
Signed-off-by: Santiago Pericas-Geertsen <[email protected]>
Signed-off-by: Santiago Pericas-Geertsen <[email protected]>
Signed-off-by: Santiago Pericas-Geertsen <[email protected]>
Signed-off-by: Santiago Pericas-Geertsen <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4.x Version 4.x enhancement New feature or request OCA Verified All contributors have signed the Oracle Contributor Agreement. webserver
Projects
Status: Normal priority
Development

Successfully merging this pull request may close these issues.

2 participants