Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify semantic of cancel wf commands #849

Merged
merged 3 commits into from
Dec 3, 2024
Merged

Clarify semantic of cancel wf commands #849

merged 3 commits into from
Dec 3, 2024

Conversation

mjameswh
Copy link
Contributor

@mjameswh mjameswh commented Dec 3, 2024

What was changed

  • Add comment on RequestCancelExternalWorkflowExecution command indicating that CancelChildWorkflowExecution should be prefered for cancellation of child workflows, and removed the child_workflow_id target on the former to avoid confusion.

Why

@mjameswh mjameswh requested a review from a team as a code owner December 3, 2024 05:15
Copy link
Member

@Sushisource Sushisource left a comment

Choose a reason for hiding this comment

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

Thanks!

None => {
return Err(WFMachinesError::Fatal(
"Cancel external workflow command had empty target field"
let we: NamespacedWorkflowExecution =
Copy link
Member

Choose a reason for hiding this comment

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

The type hint should be unnecessary

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Removed the type hint + use ok_or_else instead of a match expression.

@mjameswh mjameswh merged commit 4a2368d into master Dec 3, 2024
6 checks passed
@mjameswh mjameswh deleted the cancel-child-wf branch December 3, 2024 22:33
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