-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Move concurrent connection dial limit out of healthcheck
.
#16378
Move concurrent connection dial limit out of healthcheck
.
#16378
Conversation
Review ChecklistHello reviewers! 👋 Please follow this checklist when reviewing this Pull Request. General
Tests
Documentation
New flags
If a workflow is added or modified:
Backward compatibility
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #16378 +/- ##
==========================================
+ Coverage 68.66% 69.46% +0.79%
==========================================
Files 1548 1571 +23
Lines 199083 203504 +4421
==========================================
+ Hits 136694 141357 +4663
+ Misses 62389 62147 -242 ☔ View full report in Codecov by Sentry. |
There's a concurrent connection dial limit implemented in the healthcheck code that doesn't semantically or logically belong here. First, the healthcheck code does neither know nor care about the network protocol used to execute healthchecks. Arguably, there's no other protocol used for this apart from `grpc`, but it seems wrong to set up a `grpc` connection specific options in the healthcheck code. Additionally, the dial concurrency limit modifies the global `grpc` connection options the first time a healthcheck is started. That seems unexpected, and I believe we want the concurrency limit set for all `grpc`` dial operations, irrespective of whether those connections are used for healtchecking or anything else. This change moves the concurrency limit into the `grpcclient` package, and sets it on any `grpc` connection opened via that package. Signed-off-by: Arthur Schreiber <arthurschreiber@github.com>
df43aa0
to
9d2edb8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a bad idea. Though I believe it is vtgate where we'd need to deprecate the previous flag, not vttablet.
Let's ask Tim for the first review.
I pondered this when this was implemented. I think this is a great idea I imagine the old flag isn't used by most but a smooth depreciation of the old flag probably makes sense |
I believe both vtgate and vttablet have this because txthrottler calls discovery |
Missed some CI problems that should be addressed |
This PR is being marked as stale because it has been open for 30 days with no activity. To rectify, you may do any of the following:
If no action is taken within 7 days, this PR will be closed. |
@arthurschreiber I think this would be good to get into v21 It looks like the only thing preventing CI from passing is some e2e flag tests for the new flag. Can you update the test files? 🙇 |
Signed-off-by: Arthur Schreiber <arthurschreiber@github.com>
I think I got this right. The existing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @arthurschreiber! 🙇
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 10000 is a configurable limit from go1.2 onwards. This code could be older than this version.
We can probably point to https://pkg.go.dev/runtime/debug#SetMaxThreads
in the flag description.
Merging this to unblock release. We can change the wording of the flag in a later PR is seems reasonable. |
Description
There's a concurrent connection dial limit implemented in the healthcheck code that doesn't semantically or logically belong here.
First, the healthcheck code does neither know nor care about the network protocol used to execute healthchecks. Arguably, there's no other protocol used for this apart from
grpc
, but it seems wrong to set upgrpc
connection specific options in the healthcheck code.Additionally, the dial concurrency limit modifies the global
grpc
connection options the first time a healthcheck is started. That seems unexpected, and I believe we want the concurrency limit set for allgrpc
dial operations, irrespective of whether those connections are used for healtchecking or anything else.This change moves the concurrency limit into the
grpcclient
package, and sets it on anygrpc
connection opened via that package.This introduces a new CLI option called
--grpc-dial-concurrency-limit
for all binaries exceptvttablet
. Forvttablet
, we need to deprecate the--healthcheck-dial-concurrency
flag and replace it with--grpc-dial-concurrency-limit
as well.Related Issue(s)
Checklist
Deployment Notes