oxidecomputer / oxidecomputer/omicron
The background task subsystem could expose basic telemetry information
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 572
- Forks
- 97
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 96
Description
I was talking with @davepacheco about our existing metrics, and the idea of publishing some data from the background task subsystem came up. It seems like both valuable information and a reasonably well-understood component. The background task Driver starts a new tokio task for each registered background task:
That TaskExec is mostly a wrapper around a tokio select loop:
That waits for one of three events:
- An explicit notification
- A timeout
- All of its dependencies having finished
We already store a lot of information about the completion status of these tasks, here:
This set of data is a great candidate for publishing to oximeter. We could imagine sending the duration of each task's execution, along with:
- The task name
- The reason it ran (the
ActivationReasonenum, basically) - The outcome (success or failure, might be enough, though we do have the "details" as a JSON blob)
Making this easily available through a dashboard and / or omdb would be sweet too.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in nexus/src/app/background/common.rs, examining Driver, TaskExec, the tokio select loop, and the completion status data around the referenced lines. Determine how execution duration, task name, ActivationReason, and outcome could be published to oximeter, then clarify whether dashboard or omdb exposure is part of done.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- backend, observability
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100