Open
Description
Is there an existing feature request for this?
- I have searched the existing issues before opening this feature request.
Describe the feature you would like to see.
A metric that tracks how long the server has been running would be great. At the moment I'm using minecraft_tick_duration_seconds_count / 20 for that, but that'll be inaccurate if TPS falls below 20.
Use cases:
- I have a script that restarts the server twice per day. Occasionally there's an out of band restart, and I don't want to automatically restart the server again half an hour later.
- There's also an alert for if the restart for some reason doesn't happen.
How would you like to see this implemented?
The simplest implementation would be a static gauge that just stores the POSIX timestamp from server startup.
Slightly more convenient would be to subtract the current time from the startup time at scrape-time.
Additional information to this request.
No response
Activity