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

Reposition query submission spot for adaptive server selection #13327

Merged
merged 2 commits into from
Jun 8, 2024

Conversation

vvivekiyer
Copy link
Contributor

This is a followup to #13104

If there are cases of netty channel lock exceptions, we will avoid publishing stats for some servers as the exception handling breaks out of the loop. With this fix, we will submit stats for all picked servers and at the same time release for all servers.

@codecov-commenter
Copy link

codecov-commenter commented Jun 7, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 62.03%. Comparing base (59551e4) to head (156a8d4).
Report is 580 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master   #13327      +/-   ##
============================================
+ Coverage     61.75%   62.03%   +0.28%     
+ Complexity      207      198       -9     
============================================
  Files          2436     2545     +109     
  Lines        133233   139683    +6450     
  Branches      20636    21660    +1024     
============================================
+ Hits          82274    86656    +4382     
- Misses        44911    46476    +1565     
- Partials       6048     6551     +503     
Flag Coverage Δ
custom-integration1 <0.01% <0.00%> (-0.01%) ⬇️
integration <0.01% <0.00%> (-0.01%) ⬇️
integration1 <0.01% <0.00%> (-0.01%) ⬇️
integration2 0.00% <0.00%> (ø)
java-11 62.00% <100.00%> (+0.29%) ⬆️
java-21 61.92% <100.00%> (+0.29%) ⬆️
skip-bytebuffers-false 62.03% <100.00%> (+0.28%) ⬆️
skip-bytebuffers-true 61.89% <100.00%> (+34.17%) ⬆️
temurin 62.03% <100.00%> (+0.28%) ⬆️
unittests 62.03% <100.00%> (+0.28%) ⬆️
unittests1 46.58% <100.00%> (-0.32%) ⬇️
unittests2 27.74% <0.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

// Record stats related to query submission just before sending the request. Otherwise, if the response is
// received immediately, there's a possibility of updating query response stats before updating query
// submission stats.
_serverRoutingStatsManager.recordStatsAfterQuerySubmission(requestId, serverRoutingInstance.getInstanceId());
Copy link
Contributor

Choose a reason for hiding this comment

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

Per the method name, this should be put within either markRequestSubmitted() or markRequestSent()

Copy link
Contributor Author

Choose a reason for hiding this comment

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

For low latency usecases at high qps, this can cause the issue mentioned in comments. Hence we update the stats just before submitting.
I've updated the method name to better convey this.

@vvivekiyer vvivekiyer merged commit 61aa6ce into apache:master Jun 8, 2024
20 checks passed
@vvivekiyer vvivekiyer deleted the adss_refactor_bug branch June 8, 2024 15:57
gortiz pushed a commit to gortiz/pinot that referenced this pull request Jun 14, 2024
…e#13327)

* Refactor ADSS querysubmission stats to avoid missing servers

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

Successfully merging this pull request may close these issues.

3 participants