Files
temporal/api/workflow/v1/message.pb.go
Carly de Frondeville fe5a91ce0e Pin workflows across ContinueAsNew and implement Cross-TQ inheritance (#7776)
## What changed?
- Updated worker versioning inheritance logic for workflow chains
(parent-child and continue-as-new)
- Replaced deprecated pinned_deployment_version with new
inherited_pinned_version field in workflow execution
- Handled versioning inheritance for retry and cron workflows
- Allow cross-task-queue CaN and Child pinned version inheritance if new
task queue is in the inherited version

## Why?
- Improves versioning behavior consistency across workflow chains by
properly inheriting versioning info from parent/previous runs
- Removes deprecated fields and aligns with new versioning API design
- Fixes edge cases in versioning inheritance for retry and cron
workflows

Basically, we want `PINNED` behavior to carry through parent child
chains, and across the CaN boundary, so that we can roll out a new
behavior for Trampolining in the future, which will not be inherited
across the CaN boundary.

## How did you test it?
- [x] built
- [ ] run locally and tested manually
- [x] covered by existing tests
- [ ] added new unit test(s)
- [x] added new functional test(s)

## Potential risks
Could break history :P
2025-05-30 02:21:12 +00:00

303 lines
12 KiB
Go

// Code generated by protoc-gen-go. DO NOT EDIT.
// plugins:
// protoc-gen-go
// protoc
// source: temporal/server/api/workflow/v1/message.proto
package workflow
import (
reflect "reflect"
sync "sync"
unsafe "unsafe"
v1 "go.temporal.io/api/common/v1"
v11 "go.temporal.io/server/api/clock/v1"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
type ParentExecutionInfo struct {
state protoimpl.MessageState `protogen:"open.v1"`
NamespaceId string `protobuf:"bytes,1,opt,name=namespace_id,json=namespaceId,proto3" json:"namespace_id,omitempty"`
Namespace string `protobuf:"bytes,2,opt,name=namespace,proto3" json:"namespace,omitempty"`
Execution *v1.WorkflowExecution `protobuf:"bytes,3,opt,name=execution,proto3" json:"execution,omitempty"`
InitiatedId int64 `protobuf:"varint,4,opt,name=initiated_id,json=initiatedId,proto3" json:"initiated_id,omitempty"`
Clock *v11.VectorClock `protobuf:"bytes,5,opt,name=clock,proto3" json:"clock,omitempty"`
InitiatedVersion int64 `protobuf:"varint,6,opt,name=initiated_version,json=initiatedVersion,proto3" json:"initiated_version,omitempty"`
// When present, child workflow starts as Pinned to this Worker Deployment Version.
// Set only if the parent execution is effectively Pinned to a Worker Deployment Version when it
// first starts the child workflow, and the child workflow is starting on a Task Queue belonging
// to the same Worker Deployment Version.
// Not set in the subsequent execution if the child workflow continues-as-new.
// Deprecated. Replaced with `inherited_pinned_version` in WorkflowExecutionStartedEventAttributes.
PinnedWorkerDeploymentVersion string `protobuf:"bytes,7,opt,name=pinned_worker_deployment_version,json=pinnedWorkerDeploymentVersion,proto3" json:"pinned_worker_deployment_version,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *ParentExecutionInfo) Reset() {
*x = ParentExecutionInfo{}
mi := &file_temporal_server_api_workflow_v1_message_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *ParentExecutionInfo) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*ParentExecutionInfo) ProtoMessage() {}
func (x *ParentExecutionInfo) ProtoReflect() protoreflect.Message {
mi := &file_temporal_server_api_workflow_v1_message_proto_msgTypes[0]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use ParentExecutionInfo.ProtoReflect.Descriptor instead.
func (*ParentExecutionInfo) Descriptor() ([]byte, []int) {
return file_temporal_server_api_workflow_v1_message_proto_rawDescGZIP(), []int{0}
}
func (x *ParentExecutionInfo) GetNamespaceId() string {
if x != nil {
return x.NamespaceId
}
return ""
}
func (x *ParentExecutionInfo) GetNamespace() string {
if x != nil {
return x.Namespace
}
return ""
}
func (x *ParentExecutionInfo) GetExecution() *v1.WorkflowExecution {
if x != nil {
return x.Execution
}
return nil
}
func (x *ParentExecutionInfo) GetInitiatedId() int64 {
if x != nil {
return x.InitiatedId
}
return 0
}
func (x *ParentExecutionInfo) GetClock() *v11.VectorClock {
if x != nil {
return x.Clock
}
return nil
}
func (x *ParentExecutionInfo) GetInitiatedVersion() int64 {
if x != nil {
return x.InitiatedVersion
}
return 0
}
func (x *ParentExecutionInfo) GetPinnedWorkerDeploymentVersion() string {
if x != nil {
return x.PinnedWorkerDeploymentVersion
}
return ""
}
type RootExecutionInfo struct {
state protoimpl.MessageState `protogen:"open.v1"`
Execution *v1.WorkflowExecution `protobuf:"bytes,1,opt,name=execution,proto3" json:"execution,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *RootExecutionInfo) Reset() {
*x = RootExecutionInfo{}
mi := &file_temporal_server_api_workflow_v1_message_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *RootExecutionInfo) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*RootExecutionInfo) ProtoMessage() {}
func (x *RootExecutionInfo) ProtoReflect() protoreflect.Message {
mi := &file_temporal_server_api_workflow_v1_message_proto_msgTypes[1]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use RootExecutionInfo.ProtoReflect.Descriptor instead.
func (*RootExecutionInfo) Descriptor() ([]byte, []int) {
return file_temporal_server_api_workflow_v1_message_proto_rawDescGZIP(), []int{1}
}
func (x *RootExecutionInfo) GetExecution() *v1.WorkflowExecution {
if x != nil {
return x.Execution
}
return nil
}
type BaseExecutionInfo struct {
state protoimpl.MessageState `protogen:"open.v1"`
RunId string `protobuf:"bytes,1,opt,name=run_id,json=runId,proto3" json:"run_id,omitempty"`
LowestCommonAncestorEventId int64 `protobuf:"varint,2,opt,name=lowest_common_ancestor_event_id,json=lowestCommonAncestorEventId,proto3" json:"lowest_common_ancestor_event_id,omitempty"`
LowestCommonAncestorEventVersion int64 `protobuf:"varint,3,opt,name=lowest_common_ancestor_event_version,json=lowestCommonAncestorEventVersion,proto3" json:"lowest_common_ancestor_event_version,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *BaseExecutionInfo) Reset() {
*x = BaseExecutionInfo{}
mi := &file_temporal_server_api_workflow_v1_message_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *BaseExecutionInfo) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*BaseExecutionInfo) ProtoMessage() {}
func (x *BaseExecutionInfo) ProtoReflect() protoreflect.Message {
mi := &file_temporal_server_api_workflow_v1_message_proto_msgTypes[2]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use BaseExecutionInfo.ProtoReflect.Descriptor instead.
func (*BaseExecutionInfo) Descriptor() ([]byte, []int) {
return file_temporal_server_api_workflow_v1_message_proto_rawDescGZIP(), []int{2}
}
func (x *BaseExecutionInfo) GetRunId() string {
if x != nil {
return x.RunId
}
return ""
}
func (x *BaseExecutionInfo) GetLowestCommonAncestorEventId() int64 {
if x != nil {
return x.LowestCommonAncestorEventId
}
return 0
}
func (x *BaseExecutionInfo) GetLowestCommonAncestorEventVersion() int64 {
if x != nil {
return x.LowestCommonAncestorEventVersion
}
return 0
}
var File_temporal_server_api_workflow_v1_message_proto protoreflect.FileDescriptor
const file_temporal_server_api_workflow_v1_message_proto_rawDesc = "" +
"\n" +
"-temporal/server/api/workflow/v1/message.proto\x12\x1ftemporal.server.api.workflow.v1\x1a$temporal/api/common/v1/message.proto\x1a*temporal/server/api/clock/v1/message.proto\"\xff\x02\n" +
"\x13ParentExecutionInfo\x12!\n" +
"\fnamespace_id\x18\x01 \x01(\tR\vnamespaceId\x12\x1c\n" +
"\tnamespace\x18\x02 \x01(\tR\tnamespace\x12G\n" +
"\texecution\x18\x03 \x01(\v2).temporal.api.common.v1.WorkflowExecutionR\texecution\x12!\n" +
"\finitiated_id\x18\x04 \x01(\x03R\vinitiatedId\x12?\n" +
"\x05clock\x18\x05 \x01(\v2).temporal.server.api.clock.v1.VectorClockR\x05clock\x12+\n" +
"\x11initiated_version\x18\x06 \x01(\x03R\x10initiatedVersion\x12G\n" +
" pinned_worker_deployment_version\x18\a \x01(\tR\x1dpinnedWorkerDeploymentVersionJ\x04\b\b\x10\t\"\\\n" +
"\x11RootExecutionInfo\x12G\n" +
"\texecution\x18\x01 \x01(\v2).temporal.api.common.v1.WorkflowExecutionR\texecution\"\xc0\x01\n" +
"\x11BaseExecutionInfo\x12\x15\n" +
"\x06run_id\x18\x01 \x01(\tR\x05runId\x12D\n" +
"\x1flowest_common_ancestor_event_id\x18\x02 \x01(\x03R\x1blowestCommonAncestorEventId\x12N\n" +
"$lowest_common_ancestor_event_version\x18\x03 \x01(\x03R lowestCommonAncestorEventVersionB0Z.go.temporal.io/server/api/workflow/v1;workflowb\x06proto3"
var (
file_temporal_server_api_workflow_v1_message_proto_rawDescOnce sync.Once
file_temporal_server_api_workflow_v1_message_proto_rawDescData []byte
)
func file_temporal_server_api_workflow_v1_message_proto_rawDescGZIP() []byte {
file_temporal_server_api_workflow_v1_message_proto_rawDescOnce.Do(func() {
file_temporal_server_api_workflow_v1_message_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_temporal_server_api_workflow_v1_message_proto_rawDesc), len(file_temporal_server_api_workflow_v1_message_proto_rawDesc)))
})
return file_temporal_server_api_workflow_v1_message_proto_rawDescData
}
var file_temporal_server_api_workflow_v1_message_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
var file_temporal_server_api_workflow_v1_message_proto_goTypes = []any{
(*ParentExecutionInfo)(nil), // 0: temporal.server.api.workflow.v1.ParentExecutionInfo
(*RootExecutionInfo)(nil), // 1: temporal.server.api.workflow.v1.RootExecutionInfo
(*BaseExecutionInfo)(nil), // 2: temporal.server.api.workflow.v1.BaseExecutionInfo
(*v1.WorkflowExecution)(nil), // 3: temporal.api.common.v1.WorkflowExecution
(*v11.VectorClock)(nil), // 4: temporal.server.api.clock.v1.VectorClock
}
var file_temporal_server_api_workflow_v1_message_proto_depIdxs = []int32{
3, // 0: temporal.server.api.workflow.v1.ParentExecutionInfo.execution:type_name -> temporal.api.common.v1.WorkflowExecution
4, // 1: temporal.server.api.workflow.v1.ParentExecutionInfo.clock:type_name -> temporal.server.api.clock.v1.VectorClock
3, // 2: temporal.server.api.workflow.v1.RootExecutionInfo.execution:type_name -> temporal.api.common.v1.WorkflowExecution
3, // [3:3] is the sub-list for method output_type
3, // [3:3] is the sub-list for method input_type
3, // [3:3] is the sub-list for extension type_name
3, // [3:3] is the sub-list for extension extendee
0, // [0:3] is the sub-list for field type_name
}
func init() { file_temporal_server_api_workflow_v1_message_proto_init() }
func file_temporal_server_api_workflow_v1_message_proto_init() {
if File_temporal_server_api_workflow_v1_message_proto != nil {
return
}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: unsafe.Slice(unsafe.StringData(file_temporal_server_api_workflow_v1_message_proto_rawDesc), len(file_temporal_server_api_workflow_v1_message_proto_rawDesc)),
NumEnums: 0,
NumMessages: 3,
NumExtensions: 0,
NumServices: 0,
},
GoTypes: file_temporal_server_api_workflow_v1_message_proto_goTypes,
DependencyIndexes: file_temporal_server_api_workflow_v1_message_proto_depIdxs,
MessageInfos: file_temporal_server_api_workflow_v1_message_proto_msgTypes,
}.Build()
File_temporal_server_api_workflow_v1_message_proto = out.File
file_temporal_server_api_workflow_v1_message_proto_goTypes = nil
file_temporal_server_api_workflow_v1_message_proto_depIdxs = nil
}