-
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
txthrottler
: move ThrottlerInterface
to go/vt/throttler
, use slices
pkg, add stats
#16248
Merged
timvaillancourt
merged 8 commits into
vitessio:main
from
timvaillancourt:txthrottler-use-slices
Jul 17, 2024
Merged
txthrottler
: move ThrottlerInterface
to go/vt/throttler
, use slices
pkg, add stats
#16248
timvaillancourt
merged 8 commits into
vitessio:main
from
timvaillancourt:txthrottler-use-slices
Jul 17, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
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
|
vitess-bot
bot
added
NeedsBackportReason
If backport labels have been applied to a PR, a justification is required
NeedsDescriptionUpdate
The description is not clear or comprehensive enough, and needs work
NeedsIssue
A linked issue is missing for this Pull Request
NeedsWebsiteDocsUpdate
What it says
labels
Jun 21, 2024
timvaillancourt
added
Type: Internal Cleanup
Component: Throttler
Component: VTTablet
and removed
NeedsDescriptionUpdate
The description is not clear or comprehensive enough, and needs work
NeedsWebsiteDocsUpdate
What it says
NeedsBackportReason
If backport labels have been applied to a PR, a justification is required
NeedsIssue
A linked issue is missing for this Pull Request
labels
Jun 21, 2024
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #16248 +/- ##
==========================================
+ Coverage 68.40% 68.59% +0.19%
==========================================
Files 1556 1544 -12
Lines 195121 197978 +2857
==========================================
+ Hits 133479 135810 +2331
- Misses 61642 62168 +526 ☔ View full report in Codecov by Sentry. |
timvaillancourt
requested review from
harshit-gangal,
systay,
shlomi-noach,
rohit-nayak-ps and
deepthi
as code owners
June 21, 2024 22:02
timvaillancourt
changed the title
Jun 21, 2024
txthrottler
: move Throttler
interface to go/vt/throttler
, use slices
pkgtxthrottler
: move ThrottlerInterface
to go/vt/throttler
, use slices
pkg
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
timvaillancourt
changed the title
Jun 22, 2024
txthrottler
: move ThrottlerInterface
to go/vt/throttler
, use slices
pkgtxthrottler
: move ThrottlerInterface
to go/vt/throttler
, use slices
pkg, add stats
5 tasks
harshit-gangal
approved these changes
Jul 15, 2024
GuptaManan100
approved these changes
Jul 17, 2024
frouioui
pushed a commit
to frouioui/vitess
that referenced
this pull request
Jul 19, 2024
…lices` pkg, add stats (vitessio#16248) Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> Signed-off-by: Florent Poinsard <florent.poinsard@outlook.fr>
timvaillancourt
added a commit
to slackhq/vitess
that referenced
this pull request
Aug 7, 2024
…lices` pkg, add stats (vitessio#16248) Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
This was referenced Aug 7, 2024
timvaillancourt
added a commit
to slackhq/vitess
that referenced
this pull request
Aug 21, 2024
* `txthrottler`: move `ThrottlerInterface` to `go/vt/throttler`, use `slices` pkg, add stats (vitessio#16248) Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * revert to `reflect` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Support passing filters to `discovery.NewHealthCheck(...)` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Update go/vt/vttablet/tabletserver/txthrottler/tx_throttler.go Co-authored-by: Matt Lord <mattalord@gmail.com> Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Address some PR suggestions Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * PR ctx suggestion Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * fix test Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * simplify updateHealthCheckCells signature Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Fix race in `replicationLagModule` of `go/vt/throttle` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> --------- Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> Co-authored-by: Matt Lord <mattalord@gmail.com>
makinje16
pushed a commit
to slackhq/vitess
that referenced
this pull request
Aug 28, 2024
* `txthrottler`: move `ThrottlerInterface` to `go/vt/throttler`, use `slices` pkg, add stats (vitessio#16248) Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * revert to `reflect` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Support passing filters to `discovery.NewHealthCheck(...)` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Update go/vt/vttablet/tabletserver/txthrottler/tx_throttler.go Co-authored-by: Matt Lord <mattalord@gmail.com> Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Address some PR suggestions Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * PR ctx suggestion Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * fix test Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * simplify updateHealthCheckCells signature Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Fix race in `replicationLagModule` of `go/vt/throttle` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> --------- Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> Co-authored-by: Matt Lord <mattalord@gmail.com>
makinje16
pushed a commit
to slackhq/vitess
that referenced
this pull request
Aug 29, 2024
* `txthrottler`: move `ThrottlerInterface` to `go/vt/throttler`, use `slices` pkg, add stats (vitessio#16248) Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * revert to `reflect` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Support passing filters to `discovery.NewHealthCheck(...)` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Update go/vt/vttablet/tabletserver/txthrottler/tx_throttler.go Co-authored-by: Matt Lord <mattalord@gmail.com> Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Address some PR suggestions Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * PR ctx suggestion Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * fix test Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * simplify updateHealthCheckCells signature Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Fix race in `replicationLagModule` of `go/vt/throttle` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> --------- Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> Co-authored-by: Matt Lord <mattalord@gmail.com>
makinje16
added a commit
to slackhq/vitess
that referenced
this pull request
Sep 24, 2024
…tessio#13582) (#497) * VReplication: Make Source Tablet Selection More Robust (vitessio#13582) * update sprintf args. * `slack-15.0`: pre-backport `txthrottler` crash fixes (#480) * `txthrottler`: move `ThrottlerInterface` to `go/vt/throttler`, use `slices` pkg, add stats (vitessio#16248) Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * revert to `reflect` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Support passing filters to `discovery.NewHealthCheck(...)` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Update go/vt/vttablet/tabletserver/txthrottler/tx_throttler.go Co-authored-by: Matt Lord <mattalord@gmail.com> Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Address some PR suggestions Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * PR ctx suggestion Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * fix test Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * simplify updateHealthCheckCells signature Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Fix race in `replicationLagModule` of `go/vt/throttle` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> --------- Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> Co-authored-by: Matt Lord <mattalord@gmail.com> * ignore unused wrangler weighted semaphore --------- Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> Co-authored-by: Tim Vaillancourt <tim@timvaillancourt.com> Co-authored-by: Matt Lord <mattalord@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR cleans up the
txthrottler
code by:ThrottlerInterface interface
used to mock*throttler.Throttler
=>go/vt/throttler
Throttler interface
*throttler.Throttler
becomes*throttler.ThrottlerImpl
.Log()
method +Results struct
to supportThrottler
interfaceslices.Equal
(vsreflect.DeepEqual
) to compare cell slicestxthrottler
Related Issue(s)
I'm not sure if code cleanup needs an issue - let me know!
Checklist
Deployment Notes