-
Notifications
You must be signed in to change notification settings - Fork 76
push: add PushOnShutdown option to push metrics on shutdown #103
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
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #103 +/- ##
==========================================
- Coverage 87.58% 87.46% -0.12%
==========================================
Files 12 12
Lines 1643 1652 +9
==========================================
+ Hits 1439 1445 +6
- Misses 153 155 +2
- Partials 51 52 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
makasim
left a comment
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.
LGTM
This feature might be useful for processes with short lifetime, like CLI tools. For example, vmbackup process might finish before the first metrics reporting. With PushOnShutdown=true it would report metrics on Stop() call.
b4bf823 to
6e175c1
Compare
Push metrics on shutdown if `-pushmetrics.url` is configured. Before metrics reporting might have been skipped because of shutdown. Obsoletes VictoriaMetrics/metrics#103 Signed-off-by: hagen1778 <[email protected]>
|
Closing in favour of VictoriaMetrics/VictoriaMetrics#9767 |
Push metrics on shutdown if `-pushmetrics.url` is configured. Before metrics reporting might have been skipped because of shutdown. Obsoletes VictoriaMetrics/metrics#103 -------------- To test: 1. Run local VictoriaMetrics instance 2. Build and run vmbackup or vmrestore: ``` make vmbackup && ./bin/vmbackup -storageDataPath=victoria-metrics-data -snapshot.createURL="http://user:pass@localhost:8428/snapshot/create?authKey=foobar" -dst=fs:////vmbackup/dir -pushmetrics.url=http://localhost:8428/api/v1/import/prometheus,http://127.0.0.1:8428/api/v1/import/prometheus ``` 3. Try playing with `-pushmetrics.url` (good/bad/many addresses) and observe logs Related PR #9767
Push metrics on shutdown if `-pushmetrics.url` is configured. Before metrics reporting might have been skipped because of shutdown. Obsoletes VictoriaMetrics/metrics#103 -------------- To test: 1. Run local VictoriaMetrics instance 2. Build and run vmbackup or vmrestore: ``` make vmbackup && ./bin/vmbackup -storageDataPath=victoria-metrics-data -snapshot.createURL="http://user:pass@localhost:8428/snapshot/create?authKey=foobar" -dst=fs:////vmbackup/dir -pushmetrics.url=http://localhost:8428/api/v1/import/prometheus,http://127.0.0.1:8428/api/v1/import/prometheus ``` 3. Try playing with `-pushmetrics.url` (good/bad/many addresses) and observe logs Related PR #9767
This feature might be useful for processes with short lifetime, like CLI tools. For example, vmbackup process might finish before the first metrics reporting. With PushOnShutdown=true it would report metrics on Stop() call.