Skip to content

Commit 592d53b

Browse files
committed
Fix first_execution_run_id comments on Cancel and Terminate RPCs
The comments on RequestCancelWorkflowExecution and TerminateWorkflowExecution claimed that first_execution_run_id validates against either the most recent or specified (by run id) execution. In reality, the server unconditionally ignores the run id when first_execution_run_id is set, always resolving to the most recent execution for the workflow id. The UpdateWorkflowExecution comment is left unchanged because its server implementation does respect the run id when set.
1 parent 6895f0b commit 592d53b

1 file changed

Lines changed: 8 additions & 6 deletions

File tree

temporal/api/workflowservice/v1/request_response.proto

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -737,9 +737,10 @@ message RequestCancelWorkflowExecutionRequest {
737737
string identity = 3;
738738
// Used to de-dupe cancellation requests
739739
string request_id = 4;
740-
// If set, this call will error if the most recent (if no run id is set on
741-
// `workflow_execution`), or specified (if it is) workflow execution is not part of the same
742-
// execution chain as this id.
740+
// If set, the run id on `workflow_execution` is ignored and the most recent
741+
// workflow execution for the given workflow id is resolved. This call will
742+
// then error if that execution is not part of the same execution chain as
743+
// this id.
743744
string first_execution_run_id = 5;
744745
// Reason for requesting the cancellation
745746
string reason = 6;
@@ -887,9 +888,10 @@ message TerminateWorkflowExecutionRequest {
887888
temporal.api.common.v1.Payloads details = 4;
888889
// The identity of the worker/client
889890
string identity = 5;
890-
// If set, this call will error if the most recent (if no run id is set on
891-
// `workflow_execution`), or specified (if it is) workflow execution is not part of the same
892-
// execution chain as this id.
891+
// If set, the run id on `workflow_execution` is ignored and the most recent
892+
// workflow execution for the given workflow id is resolved. This call will
893+
// then error if that execution is not part of the same execution chain as
894+
// this id.
893895
string first_execution_run_id = 6;
894896

895897
// Links to be associated with the WorkflowExecutionTerminated event.

0 commit comments

Comments
 (0)