Repository navigation
Multirack join service part 4 - #11143
andrewjstone wants to merge 34 commits into
Conversation
|
This is finally ready for a review. |
This relies on oxidecomputer/omicron#11143 which must be merged first. It removes the pre-existing shell commands and uses actual omicron reconcilliation of dendrite and maghemite to ensure interconnect ports are created and DDM routes exchanged over them.
| } | ||
|
|
||
| fn switch_zone_ddm_router_id(baseboard: &Baseboard) -> String { | ||
| format!("sw{}", baseboard.identifier()) |
There was a problem hiding this comment.
Is the sw prefix special or meaningful to ddm?
There was a problem hiding this comment.
@rcgoodfellow added that one. I'm not sure what the goal was there.
There was a problem hiding this comment.
I think we at least need some comments explaining this. I'm not sure if it's:
- we're prefixing
swfor humans to debug that this is something in a switch zone, but it doesn't matter for correctness - the prefix of
swis special to ddm in some way - we need any kind of prefix/suffix because if we used just
baseboard.identifier().to_string()something would break because now the switch zone ID matches the gz ID
or something else
Also bump magehmite versions
| }; | ||
|
|
||
| let ports = UplinkPorts::new(ports) | ||
| .context("rack network config must specify at least one uplink port")?; |
There was a problem hiding this comment.
Will this still fail if the config specifies only DDM ports and no uplink ports? (We should reject that combo somehow, right?)
Similarly, but not sure where, should we reject any configs targeting the multirack join service that don't specify any DDM ports? (Or in the future, don't specify any ports configured for connection to a proto rack?)
There was a problem hiding this comment.
Ah you're correct. I fixed the implementation so it does so now in afdd508.
Unfortunately, the name is still confusingly UplinkPorts. But that really is not on the table to change right now.
There was a problem hiding this comment.
I'll have to think a bit more about your second question tomorrow.
There was a problem hiding this comment.
This change actually resulted in a couple of tests failing. In particular we can't just have a single port that has allow_ddm_traffic = true. That messes with the proptest change I made to populate that field rather than hardcode to false. I reverted that prior change so that we don't set allow_ddm_traffic = true in the Arbitrary. I don't think it's that big a deal for testing here.
Changed in 59d655b
| } | ||
|
|
||
| fn switch_zone_ddm_router_id(baseboard: &Baseboard) -> String { | ||
| format!("sw{}", baseboard.identifier()) |
There was a problem hiding this comment.
I think we at least need some comments explaining this. I'm not sure if it's:
- we're prefixing
swfor humans to debug that this is something in a switch zone, but it doesn't matter for correctness - the prefix of
swis special to ddm in some way - we need any kind of prefix/suffix because if we used just
baseboard.identifier().to_string()something would break because now the switch zone ID matches the gz ID
or something else
| // The two variants name their speed and FEC fields differently, so the | ||
| // required speed key is what selects the variant. |
There was a problem hiding this comment.
This seems pretty janky for a few reasons:
- The comment may not even be right - the FEC fields are both
fec, right? - Why would their speed fields be named differently when they're specifying the same thing?
- If we fix 2, do we now break our ability to distinguish between the variants?
Should we either have some explicit kind = "ddm|uplink" field in UnvalidatedPortConfig, or make it itself an enum and push this up a level?
There was a problem hiding this comment.
Agreed. This was gross, and I'm ashamed of sending it out for review that way. I changed this to properly serialize UserSpecifiedPortConfig with a tag, and then deserialize into UnvalidatedPortConfig as an intermediate so that we could handle untagged uplink versions still, which is what we currently use in our production RSS files.
This still needs a bit of testing on my side, but looks right to me.
There was a problem hiding this comment.
This doesn't work right. The direction is correct, but I'm going to have to play around with the structure a bit.
There was a problem hiding this comment.
Ok, this works now as of 3f57914.
I added intermediate untagged values to deserialize into and utilized adjacent tagging. This allows automated serialization and deserialization of UserSpecifiedPortConfig that also deals with legacy untagged uplinks.
|
I think this is pretty close @jgallagher except for the question around the sw prefix. Given all the changes though, I want to give it another run through voxel tomorrow. |
Note to reviewers: This is not as bad as it looks there's at least 800 lines of JSON here.
This is the last bit of work for #10637 that got us to Friday's demo where
/64 addresses for sleds were published via DDM running over front ports.
There's a bunch of stuff in here, but at a high level it comes down to the following:
MultirackJoinRequestto the multirack join service.RackNetworkConfiginto the bootstore so that it can be reconciled.allow_ddm_trafficviadpd-clientddm-admin-client.This code relies on new maghemite code on branch
ry/external-peers. The necessary dendrite changes are already merged into main. The maghemite PR must be completed and merged before this goes in.All of this was tested using a voxel PR that must be merged after this PR.