Skip to content

nexus: use debug dropbox to save Reconfigurator state#10306

Draft
davepacheco wants to merge 1 commit intomainfrom
dap/blueprint-archive-nexus
Draft

nexus: use debug dropbox to save Reconfigurator state#10306
davepacheco wants to merge 1 commit intomainfrom
dap/blueprint-archive-nexus

Conversation

@davepacheco
Copy link
Copy Markdown
Collaborator

Part of #7278.

@davepacheco davepacheco force-pushed the dap/blueprint-archive-nexus branch from ce37d0b to aefe883 Compare April 22, 2026 02:44
Comment thread Cargo.toml
omicron-cockroach-metrics = { path = "cockroach-metrics" }
omicron-common = { path = "common" }
# XXX-dap publish
omicron-debug-dropbox = { git = "https://github.com/oxidecomputer/omicron-debug-dropbox", rev = "13e5461bc3a725789ae6463d2b3b7d64528ffdde" }
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Once oxidecomputer/omicron-debug-dropbox#1 lands, we can publish that crate to crates.io and then update this reference.

@davepacheco davepacheco requested a review from jgallagher April 22, 2026 02:44
@davepacheco
Copy link
Copy Markdown
Collaborator Author

This is ready for review. I'm leaving it "draft" so I don't accidentally land it with the Cargo.toml change unfixed.

Copy link
Copy Markdown
Contributor

@jgallagher jgallagher left a comment

Choose a reason for hiding this comment

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

LGTM - only one real concern and a few nits.

rx_config_loader,
rx_inventory,
rx_loader.clone(),
debug_dropbox,
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.

Could/should we update this test to confirm the planner wrote the expected (or at least a valid) debug state file into the dropbox?

BlueprintDebugAction::Plan => "plan",
BlueprintDebugAction::Target => "target",
};
let time_str = blueprint.time_created.format("%Y%m%dT%H%MZ");
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.

Could this be

Suggested change
let time_str = blueprint.time_created.format("%Y%m%dT%H%MZ");
let time_str = blueprint.time_created.to_rfc3339_opts(SecondsFormat::Secs, true);

? I guess that's slightly different in that it includes -s and :s - is the idea that those are annoying in filenames?

/// someone explicitly ran the planner using the Nexus internal API
/// (likely a person running `omdb`)
Plan,
/// someone explicit set the target blueprint using the Nexus internal API
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.

Suggested change
/// someone explicit set the target blueprint using the Nexus internal API
/// someone explicitly set the target blueprint using the Nexus internal API

input,
vec![(*collection).clone()],
vec![(*parent).clone(), blueprint.clone()],
target,
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.

Will it be confusing if we persist a state claiming this new blueprint is the target, but then fail to make it the target and fail to remove it because sled-agent already slurped it up? We've now archived a state file that claims a blueprint was the target when it never was.

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