Skip to content

Conversation

@iximeow
Copy link
Member

@iximeow iximeow commented Oct 1, 2024

Greg and Eliza were both right in comments on #6585, but since these are both fully internal I didn't want to add another CI round trip there :)

Greg and Eliza were both right in comments on #6585, but since these are
both fully internal I didn't want to add another CI round trip there :)
@iximeow iximeow requested review from gjcolombo and hawkw October 1, 2024 20:01
Copy link
Member

@hawkw hawkw left a comment

Choose a reason for hiding this comment

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

let's goooo!

Comment on lines +1113 to +1115
if params.create_params.boot_disk.is_none() {
return Ok(());
}
Copy link
Member

Choose a reason for hiding this comment

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

Hmm...it occurs to me that it might be nicer to just change the make_saga_dag function to just not append a sic_set_boot_disk node if there is no boot disk param. Like, change this:

builder.append(set_boot_disk_action());

to:

if params.create_params.boot_disk.is_some() {
    builder.append(set_boot_disk_action());
}

That way, we would never do the forward or reverse action if there's no boot disk.

Copy link
Member Author

Choose a reason for hiding this comment

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

... huh, i suppose that makes sense. i'd read something in one of the comments here about Steno not handling dynamically-shaped sagas, but the comment earlier about MAX_NICS_PER_INSTANCE makes me think i'd read something old without realizing it.

Copy link
Member

Choose a reason for hiding this comment

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

Hm...a saga's DAG can definitely depend on its params, so it's possible that the comment either meant something else by "dynamically-shaped", or was just out of date...

Copy link
Contributor

@gjcolombo gjcolombo left a comment

Choose a reason for hiding this comment

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

LGTM, with a +1 to @hawkw's suggestion to just omit the set-boot-disk node from the create saga if the params don't specify that it's required.

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.

4 participants