oxidecomputer / oxidecomputer/omicron
Asynchronous APIs
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 572
- Forks
- 97
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 96
Description
Note: async is overloaded. Usage here refers to an "asynchronous endpoint", as described in RFD 4, not the async Rust keyword.
As discussed in https://github.com/oxidecomputer/omicron/pull/385#issuecomment-969200604 , Omicron is growing a reasonably sized API surface. As @davepacheco mentioned, "most things that use sagas... probably ought to be async".
At the time of writing this bug, none of our endpoints are async. We would benefit from:
- Identifying long-running operations, and defining a set which are good candidates to be async (at minimum, "create instance" seems like a good candidate).
- Prototype a couple endpoints as async, returning an ID, and providing a wait-for-completion API.
- Iterate on ergonomics, providing utilities (or possibly changes to Dropshot) making these operations as easy to write as possible.
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 with RFD 4 and the discussion linked from pull request 385 to understand asynchronous endpoint semantics. Identify long-running operations, beginning with create instance, then review how a couple of endpoints could return an ID and expose wait-for-completion APIs. Done means a defined candidate set, prototypes, and an agreed ergonomic direction, including whether Dropshot needs changes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- api, backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100