Keep last metrics for finished jobs#2628
Conversation
The retention window is 1800 seconds (last 30 minutes) by default, configurable via the `DSTACK_SERVER_METRICS_WINDOW_SECONDS` environment variable. Closes: #2618
|
Anything required on the UI's side? |
|
So the last 30 minutes of logs are stored forever after the run is finished? @peterschmidt85 is this what you proposed or having logs for some time after runs finish would be sufficient? |
|
Ideally of course we could introduce a TTL but I assume we don't support it yet for logs too? |
|
@peterschmidt85, sorry I meant metrics of course not logs. We already had a ttl for metrics: And the ttl applied to finished runs as well. So you could see metrics of finished runs for this ttl. So what this PR does I believe is keeps last metrics of finished runs forever. |
|
That was TTL for metrics of a live run. For finished run, I guess it makes sense to set TTL as a week or so. We discussed that with @un-def no? |
Well, it applied to all runs before. If the idea is to introduce different TTLs for active and finished runs, it's not what the PR does. |
I've just replaced the retention window with a simpler solution using two separate TTL settings for running and finished jobs. By default:
|
The retention window is 1800 seconds (last 30 minutes) by default, configurable via the
DSTACK_SERVER_METRICS_WINDOW_SECONDSenvironment variable.Closes: #2618