Skip to content

[10/n] [sled-agent] make RackNetworkConfig ports a non-empty UplinkPorts newtype#10651

Merged
sunshowers merged 5 commits into
mainfrom
sunshowers/spr/10n-sled-agent-make-racknetworkconfig-ports-a-non-empty-uplinkports-newtype
Jul 1, 2026
Merged

[10/n] [sled-agent] make RackNetworkConfig ports a non-empty UplinkPorts newtype#10651
sunshowers merged 5 commits into
mainfrom
sunshowers/spr/10n-sled-agent-make-racknetworkconfig-ports-a-non-empty-uplinkports-newtype

Conversation

@sunshowers

@sunshowers sunshowers commented Jun 21, 2026

Copy link
Copy Markdown
Contributor

In prior commits in the stack, we made it so that transient DB errors don't result in a partially-generated config. This change encodes one specific form of that (non-empty ports) into the type system.

Making bootstore deserialization fallible is an improvement in this case, because it turns a panic into a loop.

Also include a change to make the rack ID in StartSledAgentRequest a typed RackUuid. This isn't directly related but is spiritually similar and I'm touching this code anyway.

Depends on:

Created using spr 1.3.6-beta.1

[skip ci]
Created using spr 1.3.6-beta.1
Created using spr 1.3.6-beta.1

@jgallagher jgallagher left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wonderful 🎉

Comment thread nexus/test-utils/src/starter.rs Outdated
@sunshowers sunshowers changed the base branch from sunshowers/spr/main.10n-sled-agent-make-racknetworkconfig-ports-a-non-empty-uplinkports-newtype to main June 30, 2026 20:46
Created using spr 1.3.6-beta.1
@sunshowers sunshowers enabled auto-merge (squash) June 30, 2026 20:51
Created using spr 1.3.6-beta.1
@sunshowers sunshowers merged commit 02d41ee into main Jul 1, 2026
19 checks passed
@sunshowers sunshowers deleted the sunshowers/spr/10n-sled-agent-make-racknetworkconfig-ports-a-non-empty-uplinkports-newtype branch July 1, 2026 00:17
sunshowers added a commit that referenced this pull request Jul 1, 2026
Realized while working on this stack that we were still using untyped
UUIDs for the rack UUID. Since we're going to be working on multirack
soon, let's convert the UUID type over now.

Depends on:

* #10651
* earlier commits in the stack
sunshowers added a commit that referenced this pull request Jul 2, 2026
Similar to the rack ID migration done in #10651, also migrate the BGP
announce set IDs over.

The address lot block ID appears to (a) always be set to the same thing
as the BGP announce set ID, and (b) be unused -- I'm not touching it
here but it would be good to understand its purpose.

Depends on:

* #10651
* #10652
* earlier commits in the stack
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants