Skip to content

Commit

Permalink
Note that deleted field numbers are ok to reuse
Browse files Browse the repository at this point in the history
  • Loading branch information
Matt McShane committed Jan 6, 2023
1 parent 7819899 commit beed924
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 27 deletions.
1 change: 1 addition & 0 deletions temporal/api/command/v1/message.proto
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,7 @@ message Command {
StartChildWorkflowExecutionCommandAttributes start_child_workflow_execution_command_attributes = 12;
SignalExternalWorkflowExecutionCommandAttributes signal_external_workflow_execution_command_attributes = 13;
UpsertWorkflowSearchAttributesCommandAttributes upsert_workflow_search_attributes_command_attributes = 14;
// 15 and 16 are available for use - they were used as part of a prototype that never made it into a release
ModifyWorkflowPropertiesCommandAttributes modify_workflow_properties_command_attributes = 17;
}
}
16 changes: 13 additions & 3 deletions temporal/api/protocol/v1/message.proto
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,26 @@ option go_package = "go.temporal.io/api/protocol/v1;messaging";
option java_package = "io.temporal.api.protocol.v1";
option java_multiple_files = true;
option java_outer_classname = "MessageProto";
option ruby_package = "Temporal::Api::Protocol::V1";
option csharp_namespace = "Temporal.Api.Protocol.V1";
option ruby_package = "Temporalio::Api::Protocol::V1";
option csharp_namespace = "Temporalt.Api.Protocol.V1";

import "google/protobuf/any.proto";

// (-- api-linter: core::0146::any=disabled
// aip.dev/not-precedent: We want runtime extensibility for the body field --)
message Message {
// An ID for this specific message.
string id = 1;

// Identifies the specific instance of a protocol to which this message
// belongs.
string protocol_id = 2;

// The event ID or command ID after which this message can be delivered. The
// effects of history up to and including this event ID should be visible to
// the code that handles this message. Set to -1 to opt out of sequencing.
int64 sequencing_id = 3;

google.protobuf.Any body = 3;
// The opaque data carried by this message.
google.protobuf.Any body = 4;
}
18 changes: 2 additions & 16 deletions temporal/api/update/v1/message.proto
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ option go_package = "go.temporal.io/api/update/v1;update";
option java_package = "io.temporal.api.update.v1";
option java_multiple_files = true;
option java_outer_classname = "MessageProto";
option ruby_package = "Temporal::Api::Update::V1";
option csharp_namespace = "Temporal.Api.Update.V1";
option ruby_package = "Temporalio::Api::Update::V1";
option csharp_namespace = "Temporalio.Api.Update.V1";

import "temporal/api/common/v1/message.proto";
import "temporal/api/enums/v1/update.proto";
Expand Down Expand Up @@ -91,20 +91,6 @@ message Request {
Input input = 2;
}

// An update protocol message that invokes a given workflow execution update
// handler. This type differs from Request only in that it carries event ID
// sequencing information.
message Invocation {
Meta meta = 1;

// The event ID after which this update can execute. The effects of
// history up to and including this event ID should be visible to the
// update when it executes.
int64 sequencing_event_id = 2;

Input input = 3;
}

// An update protocol message indicating that a workflow execution update has
// been rejected.
message Rejection {
Expand Down
13 changes: 5 additions & 8 deletions temporal/api/workflowservice/v1/request_response.proto
Original file line number Diff line number Diff line change
Expand Up @@ -1056,27 +1056,24 @@ message GetWorkerBuildIdOrderingResponse {
// (-- api-linter: core::0134=disabled
// aip.dev/not-precedent: Update RPCs don't follow Google API format. --)
message UpdateWorkflowExecutionRequest {
// A unique ID for this update
string update_id = 1;

// The namespace name of the target workflow
string namespace = 2;
string namespace = 1;
// The target workflow id and (optionally) a specific run thereof
// (-- api-linter: core::0203::optional=disabled
// aip.dev/not-precedent: false positive triggered by the word "optional" --)
temporal.api.common.v1.WorkflowExecution workflow_execution = 3;
temporal.api.common.v1.WorkflowExecution workflow_execution = 2;
// If set, this call will error if the most recent (if no run id is set on
// `workflow_execution`), or specified (if it is) workflow execution is not
// part of the same execution chain as this id.
string first_execution_run_id = 4;
string first_execution_run_id = 3;

// Describes when this request should return - basically whether the
// update is synchronous, asynchronous, or somewhere in between.
temporal.api.update.v1.WaitPolicy wait_policy = 5;
temporal.api.update.v1.WaitPolicy wait_policy = 4;

// The name under which the workflow update function is registered and the
// arguments to pass to said function.
temporal.api.update.v1.Request request = 6;
temporal.api.update.v1.Request request = 5;
}

message UpdateWorkflowExecutionResponse {
Expand Down

0 comments on commit beed924

Please sign in to comment.