Skip to content

Add overload for WorkflowStub.cancel to target exact workflow execution #2651

@Quinn-With-Two-Ns

Description

@Quinn-With-Two-Ns

Is your feature request related to a problem? Please describe.

When I call WorkflowStub.cancel I want to only target the workflow execution I used to create the stub and not the latest workflow.

Describe the solution you'd like

Add overload for WorkflowStub.cancel to target exact workflow execution instead of the latest workflow ID/execution chain

Describe alternatives you've considered

We could also look at setting first_execution_run_id, need to verify if it is properly implemented for cancel.

Additional context

We need to add an appropriate note/warning to this overload since targeting such a specific run can be flaky when using things like continue as new.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions