Merged
Conversation
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
ajm188
reviewed
Mar 23, 2023
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
Contributor
Author
Strange that pressing re-request review on @ajm188 removed @-deepthi as a reviewer, that was not my intention! Is that an opt-in feature? It only seems to happen to me on this repo 🤔 |
mattlord
reviewed
Mar 29, 2023
Member
There was a problem hiding this comment.
Just one minor suggestion. Can you also please share a snippet demonstrating how you've tested this locally in the PR description? This will also serve to confirm that it's currently behaving as you expected/desired. For example:
$ curl -s localhost:1510{0,1,2}/metrics | grep -i uptime; echo "----"; curl -s localhost:1510{0,1,2}/debug/vars | grep -i uptime
# HELP vttablet_uptime Uptime in nanoseconds
# TYPE vttablet_uptime gauge
vttablet_uptime 1.17586954958e+11
# HELP vttablet_uptime Uptime in nanoseconds
# TYPE vttablet_uptime gauge
vttablet_uptime 1.14948495917e+11
# HELP vttablet_uptime Uptime in nanoseconds
# TYPE vttablet_uptime gauge
vttablet_uptime 1.12434306125e+11
----
"Uptime": 117603836542,
"Uptime": 114965008333,
"Uptime": 112449585834,
Thanks for yet another contribution @timvaillancourt ! ❤️
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
4 tasks
ajm188
reviewed
Mar 31, 2023
Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
Contributor
Author
|
@ajm188 / @mattlord: PR updated based on suggestions 👍 Here is what the current metric looks like: $ curl -s localhost:15000/metrics | grep -i uptime
# HELP vttablet_uptime Uptime in nanoseconds
# TYPE vttablet_uptime gauge
vttablet_uptime 3.53357840381e+11
$ curl -s localhost:15000/debug/vars | grep -i uptime
"Uptime": 369659702674, |
mattlord
approved these changes
Apr 6, 2023
Member
|
Thanks, @timvaillancourt ! ❤️ |
timvaillancourt
added a commit
to slackhq/vitess
that referenced
this pull request
Jun 28, 2023
* Add `Uptime` metric to `vtgate`+`vttablet` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * move to go/vt/servenv/status.go Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Use nanoseconds for uptime Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Move Uptime metrics to servenv.go, remove dupe start time.Time Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Use serverStart time.Time Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> --------- Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
4 tasks
timvaillancourt
added a commit
to slackhq/vitess
that referenced
this pull request
May 21, 2024
* Add `Uptime` metric to `vtgate`+`vttablet` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * move to go/vt/servenv/status.go Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Use nanoseconds for uptime Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Move Uptime metrics to servenv.go, remove dupe start time.Time Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Use serverStart time.Time Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> --------- Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com>
4 tasks
timvaillancourt
added a commit
to slackhq/vitess
that referenced
this pull request
May 22, 2024
* Add `VStreamerCount` stat to `vttablet` (vitessio#11978) * Add `VStreamersActive` stat to `vttablet` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Improve desc Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Add PR suggestions Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Move to *stats.Gauge Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Single defer Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Add `Uptime` metric (vitessio#12712) * Add `Uptime` metric to `vtgate`+`vttablet` Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * move to go/vt/servenv/status.go Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Use nanoseconds for uptime Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Move Uptime metrics to servenv.go, remove dupe start time.Time Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Use serverStart time.Time Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> --------- Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * Implement the RowsColumnTypeScanType interface in the go sql driver for Vitess in order to get the column types (vitessio#12007) Signed-off-by: Johan Oskarsson <joskarsson@slack-corp.com> Signed-off-by: Johan Oskarsson <joskarsson@slack-corp.com> Co-authored-by: Johan Oskarsson <joskarsson@slack-corp.com> * Add vstream metrics to vtgate (vitessio#13098) * Add vstream metrics to vtgate Signed-off-by: twthorn <thomaswilliamthornton@gmail.com> * Update unit test name and use cell variable Signed-off-by: twthorn <thomaswilliamthornton@gmail.com> * Reset metrics for TestVStreamsCreatedAndLagMetrics, fix data race issue Signed-off-by: twthorn <thomaswilliamthornton@gmail.com> --------- Signed-off-by: twthorn <thomaswilliamthornton@gmail.com> * add lock to flaky TestValidateVersionShard test Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> * typo Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> --------- Signed-off-by: Tim Vaillancourt <tim@timvaillancourt.com> Signed-off-by: Johan Oskarsson <joskarsson@slack-corp.com> Signed-off-by: twthorn <thomaswilliamthornton@gmail.com> Co-authored-by: Johan Oskarsson <johan@oskarsson.nu> Co-authored-by: Johan Oskarsson <joskarsson@slack-corp.com> Co-authored-by: Thomas Thornton <thomaswilliamthornton@gmail.com>
This file contains hidden or 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
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 adds an
Uptimemetric togo/vt/servenvfor measuring how long a daemon has been runningRelated Issue(s)
Resolves: #12711
Checklist
Deployment Notes