Skip to content

[3/n] [sync-switch] move bfd and address lot reads back to bg task, make the builder pure#10644

Open
sunshowers wants to merge 2 commits into
sunshowers/spr/main.3n-sync-switch-move-bfd-and-address-lot-reads-back-to-bg-task-make-the-builder-purefrom
sunshowers/spr/3n-sync-switch-move-bfd-and-address-lot-reads-back-to-bg-task-make-the-builder-pure
Open

[3/n] [sync-switch] move bfd and address lot reads back to bg task, make the builder pure#10644
sunshowers wants to merge 2 commits into
sunshowers/spr/main.3n-sync-switch-move-bfd-and-address-lot-reads-back-to-bg-task-make-the-builder-purefrom
sunshowers/spr/3n-sync-switch-move-bfd-and-address-lot-reads-back-to-bg-task-make-the-builder-pure

Conversation

@sunshowers

@sunshowers sunshowers commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

Move the infra address-lot and BFD reads back into the caller, passing their results in via a new RackNetworkConfigInput struct. With those gone, the builder performs no database access at all, so it becomes a synchronous, pure function.

The nexus-switch-config crate still has dependencies on nexus-db-model and nexus-db-queries, but those are only for types. Later commits in the series will introduce domain types and get rid of this dependency.

This commit reorders some reads slightly, but otherwise is meant to be pure refactoring with no functional changes.

Depends on:

Created using spr 1.3.6-beta.1
Created using spr 1.3.6-beta.1
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.

1 participant