From 2d74fbdbd4c8ac20dd3858833ecaafae5ef4c686 Mon Sep 17 00:00:00 2001 From: Spencer Judge Date: Wed, 19 Apr 2023 10:35:26 -0700 Subject: [PATCH 1/2] Add flags for using the default build id set --- temporal/api/command/v1/message.proto | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/temporal/api/command/v1/message.proto b/temporal/api/command/v1/message.proto index 30d4b28d..94fded73 100644 --- a/temporal/api/command/v1/message.proto +++ b/temporal/api/command/v1/message.proto @@ -83,6 +83,12 @@ message ScheduleActivityTaskCommandAttributes { // Request to start the activity directly bypassing matching service and worker polling // The slot for executing the activity should be reserved when setting this field to true. bool request_eager_execution = 12; + // If this is set and the workflow executing this command is on a task queue using build-id + // versioning, then the scheduled activity will not use the same compatible version set (which + // is the default behavior) and instead will use the current overall default for the queue. + // If this command's `task_queue` field differs from the executing workflow's task queue, then + // this flag has no effect. + bool use_default_build_id_set = 13; } message RequestCancelActivityTaskCommandAttributes { @@ -191,6 +197,12 @@ message ContinueAsNewWorkflowExecutionCommandAttributes { temporal.api.common.v1.Header header = 12; temporal.api.common.v1.Memo memo = 13; temporal.api.common.v1.SearchAttributes search_attributes = 14; + // If this is set and the workflow executing this command is on a task queue using build-id + // versioning, then the continued workflow will not use the same compatible version set (which + // is the default behavior) and instead will use the current overall default for the queue. + // If this command's `task_queue` field differs from the executing workflow's task queue, then + // this flag has no effect. + bool use_default_build_id_set = 15; // `workflow_execution_timeout` is omitted as it shouldn't be overridden from within a workflow. } @@ -218,6 +230,12 @@ message StartChildWorkflowExecutionCommandAttributes { temporal.api.common.v1.Header header = 14; temporal.api.common.v1.Memo memo = 15; temporal.api.common.v1.SearchAttributes search_attributes = 16; + // If this is set and the workflow executing this command is on a task queue using build-id + // versioning, then the child workflow will not use the same compatible version set (which + // is the default behavior) and instead will use the current overall default for the queue. + // If this command's `task_queue` field differs from the executing workflow's task queue, then + // this flag has no effect. + bool use_default_build_id_set = 17; } message ProtocolMessageCommandAttributes { From d94f9132108f3f3556b019e7bef6eb21754c12f1 Mon Sep 17 00:00:00 2001 From: Spencer Judge Date: Mon, 24 Apr 2023 10:19:57 -0700 Subject: [PATCH 2/2] Add to events / change name --- temporal/api/command/v1/message.proto | 6 +++--- temporal/api/history/v1/message.proto | 18 ++++++++++++++++++ 2 files changed, 21 insertions(+), 3 deletions(-) diff --git a/temporal/api/command/v1/message.proto b/temporal/api/command/v1/message.proto index 94fded73..34fe8fe1 100644 --- a/temporal/api/command/v1/message.proto +++ b/temporal/api/command/v1/message.proto @@ -88,7 +88,7 @@ message ScheduleActivityTaskCommandAttributes { // is the default behavior) and instead will use the current overall default for the queue. // If this command's `task_queue` field differs from the executing workflow's task queue, then // this flag has no effect. - bool use_default_build_id_set = 13; + bool use_latest_build_id = 13; } message RequestCancelActivityTaskCommandAttributes { @@ -202,7 +202,7 @@ message ContinueAsNewWorkflowExecutionCommandAttributes { // is the default behavior) and instead will use the current overall default for the queue. // If this command's `task_queue` field differs from the executing workflow's task queue, then // this flag has no effect. - bool use_default_build_id_set = 15; + bool use_latest_build_id = 15; // `workflow_execution_timeout` is omitted as it shouldn't be overridden from within a workflow. } @@ -235,7 +235,7 @@ message StartChildWorkflowExecutionCommandAttributes { // is the default behavior) and instead will use the current overall default for the queue. // If this command's `task_queue` field differs from the executing workflow's task queue, then // this flag has no effect. - bool use_default_build_id_set = 17; + bool use_latest_build_id = 17; } message ProtocolMessageCommandAttributes { diff --git a/temporal/api/history/v1/message.proto b/temporal/api/history/v1/message.proto index cad2ae17..b6619338 100644 --- a/temporal/api/history/v1/message.proto +++ b/temporal/api/history/v1/message.proto @@ -152,6 +152,12 @@ message WorkflowExecutionContinuedAsNewEventAttributes { temporal.api.common.v1.Header header = 12; temporal.api.common.v1.Memo memo = 13; temporal.api.common.v1.SearchAttributes search_attributes = 14; + // If this is set and the workflow executing this command is on a task queue using build-id + // versioning, then the scheduled activity will not use the same compatible version set (which + // is the default behavior) and instead will use the current overall default for the queue. + // If this command's `task_queue` field differs from the executing workflow's task queue, then + // this flag has no effect. + bool use_latest_build_id = 15; // workflow_execution_timeout is omitted as it shouldn't be overridden from within a workflow. } @@ -270,6 +276,12 @@ message ActivityTaskScheduledEventAttributes { // configuration. Retries will happen up to `schedule_to_close_timeout`. To disable retries set // retry_policy.maximum_attempts to 1. temporal.api.common.v1.RetryPolicy retry_policy = 12; + // If this is set and the workflow executing this command is on a task queue using build-id + // versioning, then the scheduled activity will not use the same compatible version set (which + // is the default behavior) and instead will use the current overall default for the queue. + // If this command's `task_queue` field differs from the executing workflow's task queue, then + // this flag has no effect. + bool use_latest_build_id = 13; } message ActivityTaskStartedEventAttributes { @@ -556,6 +568,12 @@ message StartChildWorkflowExecutionInitiatedEventAttributes { temporal.api.common.v1.Header header = 15; temporal.api.common.v1.Memo memo = 16; temporal.api.common.v1.SearchAttributes search_attributes = 17; + // If this is set and the workflow executing this command is on a task queue using build-id + // versioning, then the child workflow will not use the same compatible version set (which + // is the default behavior) and instead will use the current overall default for the queue. + // If this command's `task_queue` field differs from the executing workflow's task queue, then + // this flag has no effect. + bool use_latest_build_id = 19; } message StartChildWorkflowExecutionFailedEventAttributes {