oxidecomputer / oxidecomputer/omicron
cockroach-admin: Don't discard node status rows that are missing some fields
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 572
- Forks
- 97
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 96
Description
So, I'm totally on-board with this PR as it exists - makes sense to prevent a single parse error from stopping the whole status endpoint - but do we want to allow parsing NULL socket addresses as valid?
Put another way: It seems like "This is how CRDB works - the address field is actually an Option". Shouldn't we update our view of the struct NodeStatus to make some of these fields optional?
(basically: I think it's great to handle parse errors and continue going, but it also seems like we could / should avoid having parse errors, if we can!)
Originally posted by @smklein in https://github.com/oxidecomputer/omicron/pull/10072#discussion_r2948705482
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 by locating the struct NodeStatus and the cockroach-admin status endpoint, then inspect how NULL socket addresses and other missing fields are parsed. Determine which fields can be absent and update the relevant coverage so missing fields do not discard status rows or stop the endpoint.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100