@superdurable/dex 0.1.5 → 0.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/README.md +102 -6
  2. package/dist/src/client.d.ts +18 -23
  3. package/dist/src/client.js +94 -65
  4. package/dist/src/client.js.map +1 -1
  5. package/dist/src/codec.d.ts +1 -1
  6. package/dist/src/context.d.ts +7 -0
  7. package/dist/src/errors.d.ts +2 -33
  8. package/dist/src/errors.js +2 -45
  9. package/dist/src/errors.js.map +1 -1
  10. package/dist/src/flow-result.d.ts +47 -0
  11. package/dist/src/flow-result.js +82 -0
  12. package/dist/src/flow-result.js.map +1 -0
  13. package/dist/src/flow.d.ts +13 -1
  14. package/dist/src/flow.js +1 -0
  15. package/dist/src/flow.js.map +1 -1
  16. package/dist/src/gen/dex.d.ts +209 -33
  17. package/dist/src/gen/dex.js +1619 -213
  18. package/dist/src/gen/dex.js.map +1 -1
  19. package/dist/src/grpc-status.js +6 -5
  20. package/dist/src/grpc-status.js.map +1 -1
  21. package/dist/src/index.d.ts +2 -0
  22. package/dist/src/index.js +1 -0
  23. package/dist/src/index.js.map +1 -1
  24. package/dist/src/invocation-context.d.ts +5 -1
  25. package/dist/src/invocation-context.js +23 -1
  26. package/dist/src/invocation-context.js.map +1 -1
  27. package/dist/src/options.d.ts +42 -19
  28. package/dist/src/options.js +20 -4
  29. package/dist/src/options.js.map +1 -1
  30. package/dist/src/rpc.d.ts +3 -1
  31. package/dist/src/rpc.js.map +1 -1
  32. package/dist/src/step.d.ts +32 -2
  33. package/dist/src/step.js +37 -0
  34. package/dist/src/step.js.map +1 -1
  35. package/dist/src/subflow.d.ts +62 -0
  36. package/dist/src/subflow.js +62 -0
  37. package/dist/src/subflow.js.map +1 -0
  38. package/dist/src/wait.d.ts +10 -2
  39. package/dist/src/wait.js.map +1 -1
  40. package/dist/src/worker-dispatcher.d.ts +4 -3
  41. package/dist/src/worker-dispatcher.js +256 -28
  42. package/dist/src/worker-dispatcher.js.map +1 -1
  43. package/dist/src/worker.js +21 -5
  44. package/dist/src/worker.js.map +1 -1
  45. package/native/linux-aarch64/dex_blob_cache_node.node +0 -0
  46. package/native/linux-x86_64/dex_blob_cache_node.node +0 -0
  47. package/native/macos-aarch64/dex_blob_cache_node.node +0 -0
  48. package/native/macos-x86_64/dex_blob_cache_node.node +0 -0
  49. package/native/windows-x86_64/dex_blob_cache_node.node +0 -0
  50. package/package.json +1 -1
@@ -63,6 +63,14 @@ export var StepDurability;
63
63
  StepDurability[StepDurability["STEP_DURABILITY_ASYNC"] = 2] = "STEP_DURABILITY_ASYNC";
64
64
  StepDurability[StepDurability["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
65
65
  })(StepDurability || (StepDurability = {}));
66
+ export var FlowTimeoutPolicy;
67
+ (function (FlowTimeoutPolicy) {
68
+ FlowTimeoutPolicy[FlowTimeoutPolicy["FLOW_TIMEOUT_POLICY_UNSPECIFIED"] = 0] = "FLOW_TIMEOUT_POLICY_UNSPECIFIED";
69
+ FlowTimeoutPolicy[FlowTimeoutPolicy["FLOW_TIMEOUT_POLICY_FAIL"] = 1] = "FLOW_TIMEOUT_POLICY_FAIL";
70
+ FlowTimeoutPolicy[FlowTimeoutPolicy["FLOW_TIMEOUT_POLICY_CANCEL"] = 2] = "FLOW_TIMEOUT_POLICY_CANCEL";
71
+ FlowTimeoutPolicy[FlowTimeoutPolicy["FLOW_TIMEOUT_POLICY_HANDLER"] = 3] = "FLOW_TIMEOUT_POLICY_HANDLER";
72
+ FlowTimeoutPolicy[FlowTimeoutPolicy["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
73
+ })(FlowTimeoutPolicy || (FlowTimeoutPolicy = {}));
66
74
  export var StopType;
67
75
  (function (StopType) {
68
76
  StopType[StopType["STOP_TYPE_UNSPECIFIED"] = 0] = "STOP_TYPE_UNSPECIFIED";
@@ -77,7 +85,8 @@ export var FlowStatus;
77
85
  FlowStatus[FlowStatus["FLOW_STATUS_RUNNING"] = 1] = "FLOW_STATUS_RUNNING";
78
86
  FlowStatus[FlowStatus["FLOW_STATUS_COMPLETED"] = 2] = "FLOW_STATUS_COMPLETED";
79
87
  FlowStatus[FlowStatus["FLOW_STATUS_FAILED"] = 3] = "FLOW_STATUS_FAILED";
80
- FlowStatus[FlowStatus["FLOW_STATUS_TIMEOUT"] = 4] = "FLOW_STATUS_TIMEOUT";
88
+ /** FLOW_STATUS_SERVER_SIDE_TIMEOUT_INTERNAL_ONLY - Reserved for reporting a backend hard timeout; applications must not depend on this status. */
89
+ FlowStatus[FlowStatus["FLOW_STATUS_SERVER_SIDE_TIMEOUT_INTERNAL_ONLY"] = 4] = "FLOW_STATUS_SERVER_SIDE_TIMEOUT_INTERNAL_ONLY";
81
90
  FlowStatus[FlowStatus["FLOW_STATUS_TERMINATED"] = 5] = "FLOW_STATUS_TERMINATED";
82
91
  FlowStatus[FlowStatus["FLOW_STATUS_CANCELED"] = 6] = "FLOW_STATUS_CANCELED";
83
92
  FlowStatus[FlowStatus["FLOW_STATUS_CONTINUED_AS_NEW"] = 7] = "FLOW_STATUS_CONTINUED_AS_NEW";
@@ -91,10 +100,19 @@ export var FlowErrorType;
91
100
  /** FLOW_ERROR_TYPE_WORKER_API_FAIL - includes waitFor/execute/rpc methods */
92
101
  FlowErrorType[FlowErrorType["FLOW_ERROR_TYPE_WORKER_API_FAIL"] = 3] = "FLOW_ERROR_TYPE_WORKER_API_FAIL";
93
102
  FlowErrorType[FlowErrorType["FLOW_ERROR_TYPE_INVALID_USER_FLOW_CODE"] = 4] = "FLOW_ERROR_TYPE_INVALID_USER_FLOW_CODE";
103
+ FlowErrorType[FlowErrorType["FLOW_ERROR_TYPE_FLOW_TIMEOUT"] = 5] = "FLOW_ERROR_TYPE_FLOW_TIMEOUT";
94
104
  /** FLOW_ERROR_TYPE_INTERNAL - either bug in sdk or server */
95
105
  FlowErrorType[FlowErrorType["FLOW_ERROR_TYPE_INTERNAL"] = 6] = "FLOW_ERROR_TYPE_INTERNAL";
96
106
  FlowErrorType[FlowErrorType["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
97
107
  })(FlowErrorType || (FlowErrorType = {}));
108
+ /** PendingStepMethodPhase reports the latest persisted backend lifecycle event. */
109
+ export var PendingStepMethodPhase;
110
+ (function (PendingStepMethodPhase) {
111
+ PendingStepMethodPhase[PendingStepMethodPhase["PENDING_STEP_METHOD_PHASE_UNSPECIFIED"] = 0] = "PENDING_STEP_METHOD_PHASE_UNSPECIFIED";
112
+ PendingStepMethodPhase[PendingStepMethodPhase["PENDING_STEP_METHOD_PHASE_SCHEDULED"] = 1] = "PENDING_STEP_METHOD_PHASE_SCHEDULED";
113
+ PendingStepMethodPhase[PendingStepMethodPhase["PENDING_STEP_METHOD_PHASE_STARTED"] = 2] = "PENDING_STEP_METHOD_PHASE_STARTED";
114
+ PendingStepMethodPhase[PendingStepMethodPhase["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
115
+ })(PendingStepMethodPhase || (PendingStepMethodPhase = {}));
98
116
  export var ActiveStepPhase;
99
117
  (function (ActiveStepPhase) {
100
118
  ActiveStepPhase[ActiveStepPhase["ACTIVE_STEP_PHASE_UNSPECIFIED"] = 0] = "ACTIVE_STEP_PHASE_UNSPECIFIED";
@@ -105,13 +123,19 @@ export var ActiveStepPhase;
105
123
  export var FlowResetType;
106
124
  (function (FlowResetType) {
107
125
  FlowResetType[FlowResetType["FLOW_RESET_TYPE_UNSPECIFIED"] = 0] = "FLOW_RESET_TYPE_UNSPECIFIED";
108
- FlowResetType[FlowResetType["FLOW_RESET_TYPE_HISTORY_EVENT_ID"] = 1] = "FLOW_RESET_TYPE_HISTORY_EVENT_ID";
109
- FlowResetType[FlowResetType["FLOW_RESET_TYPE_BEGINNING"] = 2] = "FLOW_RESET_TYPE_BEGINNING";
110
- FlowResetType[FlowResetType["FLOW_RESET_TYPE_HISTORY_EVENT_TIME"] = 3] = "FLOW_RESET_TYPE_HISTORY_EVENT_TIME";
111
- FlowResetType[FlowResetType["FLOW_RESET_TYPE_STEP_TYPE"] = 4] = "FLOW_RESET_TYPE_STEP_TYPE";
112
- FlowResetType[FlowResetType["FLOW_RESET_TYPE_STEP_EXECUTION_ID"] = 5] = "FLOW_RESET_TYPE_STEP_EXECUTION_ID";
126
+ FlowResetType[FlowResetType["FLOW_RESET_TYPE_BEGINNING"] = 1] = "FLOW_RESET_TYPE_BEGINNING";
127
+ FlowResetType[FlowResetType["FLOW_RESET_TYPE_HISTORY_EVENT_TIME"] = 2] = "FLOW_RESET_TYPE_HISTORY_EVENT_TIME";
128
+ FlowResetType[FlowResetType["FLOW_RESET_TYPE_STEP_TYPE"] = 3] = "FLOW_RESET_TYPE_STEP_TYPE";
129
+ FlowResetType[FlowResetType["FLOW_RESET_TYPE_STEP_EXECUTION_ID"] = 4] = "FLOW_RESET_TYPE_STEP_EXECUTION_ID";
113
130
  FlowResetType[FlowResetType["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
114
131
  })(FlowResetType || (FlowResetType = {}));
132
+ export var FlowResetStepMethod;
133
+ (function (FlowResetStepMethod) {
134
+ FlowResetStepMethod[FlowResetStepMethod["FLOW_RESET_STEP_METHOD_UNSPECIFIED"] = 0] = "FLOW_RESET_STEP_METHOD_UNSPECIFIED";
135
+ FlowResetStepMethod[FlowResetStepMethod["FLOW_RESET_STEP_METHOD_WAIT_FOR"] = 1] = "FLOW_RESET_STEP_METHOD_WAIT_FOR";
136
+ FlowResetStepMethod[FlowResetStepMethod["FLOW_RESET_STEP_METHOD_EXECUTE"] = 2] = "FLOW_RESET_STEP_METHOD_EXECUTE";
137
+ FlowResetStepMethod[FlowResetStepMethod["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
138
+ })(FlowResetStepMethod || (FlowResetStepMethod = {}));
115
139
  export var ErrorSubStatus;
116
140
  (function (ErrorSubStatus) {
117
141
  ErrorSubStatus[ErrorSubStatus["ERROR_SUB_STATUS_UNSPECIFIED"] = 0] = "ERROR_SUB_STATUS_UNSPECIFIED";
@@ -140,6 +164,14 @@ export var WaitingConditionType;
140
164
  WaitingConditionType[WaitingConditionType["WAITING_CONDITION_TYPE_ANY_COMBINATION_COMPLETED"] = 3] = "WAITING_CONDITION_TYPE_ANY_COMBINATION_COMPLETED";
141
165
  WaitingConditionType[WaitingConditionType["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
142
166
  })(WaitingConditionType || (WaitingConditionType = {}));
167
+ export var SubFlowReusePolicy;
168
+ (function (SubFlowReusePolicy) {
169
+ SubFlowReusePolicy[SubFlowReusePolicy["SUB_FLOW_REUSE_POLICY_UNSPECIFIED"] = 0] = "SUB_FLOW_REUSE_POLICY_UNSPECIFIED";
170
+ SubFlowReusePolicy[SubFlowReusePolicy["SUB_FLOW_REUSE_POLICY_ATTACH"] = 1] = "SUB_FLOW_REUSE_POLICY_ATTACH";
171
+ SubFlowReusePolicy[SubFlowReusePolicy["SUB_FLOW_REUSE_POLICY_RESTART_IF_PREVIOUS_EXITS_ABNORMALLY"] = 2] = "SUB_FLOW_REUSE_POLICY_RESTART_IF_PREVIOUS_EXITS_ABNORMALLY";
172
+ SubFlowReusePolicy[SubFlowReusePolicy["SUB_FLOW_REUSE_POLICY_ALWAYS_RESTART"] = 3] = "SUB_FLOW_REUSE_POLICY_ALWAYS_RESTART";
173
+ SubFlowReusePolicy[SubFlowReusePolicy["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
174
+ })(SubFlowReusePolicy || (SubFlowReusePolicy = {}));
143
175
  export var ConditionStatus;
144
176
  (function (ConditionStatus) {
145
177
  ConditionStatus[ConditionStatus["CONDITION_STATUS_UNSPECIFIED"] = 0] = "CONDITION_STATUS_UNSPECIFIED";
@@ -166,6 +198,13 @@ export var UpdateErrorType;
166
198
  UpdateErrorType[UpdateErrorType["UPDATE_ERROR_TYPE_SERVER_INTERNAL"] = 6] = "UPDATE_ERROR_TYPE_SERVER_INTERNAL";
167
199
  UpdateErrorType[UpdateErrorType["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
168
200
  })(UpdateErrorType || (UpdateErrorType = {}));
201
+ export var SubFlowCompletionDeliveryStatus;
202
+ (function (SubFlowCompletionDeliveryStatus) {
203
+ SubFlowCompletionDeliveryStatus[SubFlowCompletionDeliveryStatus["SUB_FLOW_COMPLETION_DELIVERY_STATUS_UNSPECIFIED"] = 0] = "SUB_FLOW_COMPLETION_DELIVERY_STATUS_UNSPECIFIED";
204
+ SubFlowCompletionDeliveryStatus[SubFlowCompletionDeliveryStatus["SUB_FLOW_COMPLETION_DELIVERY_STATUS_DELIVERED"] = 1] = "SUB_FLOW_COMPLETION_DELIVERY_STATUS_DELIVERED";
205
+ SubFlowCompletionDeliveryStatus[SubFlowCompletionDeliveryStatus["SUB_FLOW_COMPLETION_DELIVERY_STATUS_PARENT_CLOSED_OR_NOT_FOUND"] = 2] = "SUB_FLOW_COMPLETION_DELIVERY_STATUS_PARENT_CLOSED_OR_NOT_FOUND";
206
+ SubFlowCompletionDeliveryStatus[SubFlowCompletionDeliveryStatus["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
207
+ })(SubFlowCompletionDeliveryStatus || (SubFlowCompletionDeliveryStatus = {}));
169
208
  function createBaseValue() {
170
209
  return { kind: undefined };
171
210
  }
@@ -626,6 +665,7 @@ function createBaseContext() {
626
665
  firstAttemptTimestamp: 0n,
627
666
  attempt: 0,
628
667
  fromStepExecutionId: "",
668
+ recoveryError: undefined,
629
669
  };
630
670
  }
631
671
  export const Context = {
@@ -657,6 +697,9 @@ export const Context = {
657
697
  if (message.fromStepExecutionId !== "") {
658
698
  writer.uint32(58).string(message.fromStepExecutionId);
659
699
  }
700
+ if (message.recoveryError !== undefined) {
701
+ RecoveryErrorInfo.encode(message.recoveryError, writer.uint32(66).fork()).join();
702
+ }
660
703
  return writer;
661
704
  },
662
705
  decode(input, length) {
@@ -715,6 +758,13 @@ export const Context = {
715
758
  message.fromStepExecutionId = reader.string();
716
759
  continue;
717
760
  }
761
+ case 8: {
762
+ if (tag !== 66) {
763
+ break;
764
+ }
765
+ message.recoveryError = RecoveryErrorInfo.decode(reader, reader.uint32());
766
+ continue;
767
+ }
718
768
  }
719
769
  if ((tag & 7) === 4 || tag === 0) {
720
770
  break;
@@ -740,13 +790,16 @@ export const Context = {
740
790
  : 0n;
741
791
  message.attempt = object.attempt ?? 0;
742
792
  message.fromStepExecutionId = object.fromStepExecutionId ?? "";
793
+ message.recoveryError = (object.recoveryError !== undefined && object.recoveryError !== null)
794
+ ? RecoveryErrorInfo.fromPartial(object.recoveryError)
795
+ : undefined;
743
796
  return message;
744
797
  },
745
798
  };
746
- function createBaseLocalActivityInput() {
799
+ function createBaseLocalActivityMetadata() {
747
800
  return { currentStepExecutionId: "", fromStepExecutionId: "" };
748
801
  }
749
- export const LocalActivityInput = {
802
+ export const LocalActivityMetadata = {
750
803
  encode(message, writer = new BinaryWriter()) {
751
804
  if (message.currentStepExecutionId !== "") {
752
805
  writer.uint32(10).string(message.currentStepExecutionId);
@@ -759,7 +812,7 @@ export const LocalActivityInput = {
759
812
  decode(input, length) {
760
813
  const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
761
814
  const end = length === undefined ? reader.len : reader.pos + length;
762
- const message = createBaseLocalActivityInput();
815
+ const message = createBaseLocalActivityMetadata();
763
816
  while (reader.pos < end) {
764
817
  const tag = reader.uint32();
765
818
  switch (tag >>> 3) {
@@ -786,10 +839,10 @@ export const LocalActivityInput = {
786
839
  return message;
787
840
  },
788
841
  create(base) {
789
- return LocalActivityInput.fromPartial(base ?? {});
842
+ return LocalActivityMetadata.fromPartial(base ?? {});
790
843
  },
791
844
  fromPartial(object) {
792
- const message = createBaseLocalActivityInput();
845
+ const message = createBaseLocalActivityMetadata();
793
846
  message.currentStepExecutionId = object.currentStepExecutionId ?? "";
794
847
  message.fromStepExecutionId = object.fromStepExecutionId ?? "";
795
848
  return message;
@@ -975,6 +1028,7 @@ function createBaseStepOptions() {
975
1028
  executeDurabilityOverride: 0,
976
1029
  waitForLockAttributeKeys: [],
977
1030
  executeLockAttributeKeys: [],
1031
+ heartbeatTimeoutSeconds: 0,
978
1032
  };
979
1033
  }
980
1034
  export const StepOptions = {
@@ -1018,6 +1072,9 @@ export const StepOptions = {
1018
1072
  for (const v of message.executeLockAttributeKeys) {
1019
1073
  writer.uint32(106).string(v);
1020
1074
  }
1075
+ if (message.heartbeatTimeoutSeconds !== 0) {
1076
+ writer.uint32(112).int32(message.heartbeatTimeoutSeconds);
1077
+ }
1021
1078
  return writer;
1022
1079
  },
1023
1080
  decode(input, length) {
@@ -1118,6 +1175,13 @@ export const StepOptions = {
1118
1175
  message.executeLockAttributeKeys.push(reader.string());
1119
1176
  continue;
1120
1177
  }
1178
+ case 14: {
1179
+ if (tag !== 112) {
1180
+ break;
1181
+ }
1182
+ message.heartbeatTimeoutSeconds = reader.int32();
1183
+ continue;
1184
+ }
1121
1185
  }
1122
1186
  if ((tag & 7) === 4 || tag === 0) {
1123
1187
  break;
@@ -1151,6 +1215,7 @@ export const StepOptions = {
1151
1215
  message.executeDurabilityOverride = object.executeDurabilityOverride ?? 0;
1152
1216
  message.waitForLockAttributeKeys = object.waitForLockAttributeKeys?.map((e) => e) || [];
1153
1217
  message.executeLockAttributeKeys = object.executeLockAttributeKeys?.map((e) => e) || [];
1218
+ message.heartbeatTimeoutSeconds = object.heartbeatTimeoutSeconds ?? 0;
1154
1219
  return message;
1155
1220
  },
1156
1221
  };
@@ -1479,6 +1544,7 @@ function createBaseStartFlowRequest() {
1479
1544
  flowId: "",
1480
1545
  flowType: "",
1481
1546
  flowTimeoutSeconds: 0,
1547
+ flowTimeoutPolicy: 0,
1482
1548
  startStepType: "",
1483
1549
  stepInput: undefined,
1484
1550
  stepOptions: undefined,
@@ -1497,6 +1563,9 @@ export const StartFlowRequest = {
1497
1563
  if (message.flowTimeoutSeconds !== 0) {
1498
1564
  writer.uint32(24).int32(message.flowTimeoutSeconds);
1499
1565
  }
1566
+ if (message.flowTimeoutPolicy !== 0) {
1567
+ writer.uint32(32).int32(message.flowTimeoutPolicy);
1568
+ }
1500
1569
  if (message.startStepType !== "") {
1501
1570
  writer.uint32(42).string(message.startStepType);
1502
1571
  }
@@ -1542,6 +1611,13 @@ export const StartFlowRequest = {
1542
1611
  message.flowTimeoutSeconds = reader.int32();
1543
1612
  continue;
1544
1613
  }
1614
+ case 4: {
1615
+ if (tag !== 32) {
1616
+ break;
1617
+ }
1618
+ message.flowTimeoutPolicy = reader.int32();
1619
+ continue;
1620
+ }
1545
1621
  case 5: {
1546
1622
  if (tag !== 42) {
1547
1623
  break;
@@ -1593,6 +1669,7 @@ export const StartFlowRequest = {
1593
1669
  message.flowId = object.flowId ?? "";
1594
1670
  message.flowType = object.flowType ?? "";
1595
1671
  message.flowTimeoutSeconds = object.flowTimeoutSeconds ?? 0;
1672
+ message.flowTimeoutPolicy = object.flowTimeoutPolicy ?? 0;
1596
1673
  message.startStepType = object.startStepType ?? "";
1597
1674
  message.stepInput = (object.stepInput !== undefined && object.stepInput !== null)
1598
1675
  ? Value.fromPartial(object.stepInput)
@@ -2307,10 +2384,10 @@ export const StepCompletionOutput = {
2307
2384
  return message;
2308
2385
  },
2309
2386
  };
2310
- function createBaseWaitForFlowResponse() {
2387
+ function createBaseFlowResult() {
2311
2388
  return { flowStatus: 0, results: [], errorType: 0, errorMessage: "" };
2312
2389
  }
2313
- export const WaitForFlowResponse = {
2390
+ export const FlowResult = {
2314
2391
  encode(message, writer = new BinaryWriter()) {
2315
2392
  if (message.flowStatus !== 0) {
2316
2393
  writer.uint32(8).int32(message.flowStatus);
@@ -2329,7 +2406,7 @@ export const WaitForFlowResponse = {
2329
2406
  decode(input, length) {
2330
2407
  const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
2331
2408
  const end = length === undefined ? reader.len : reader.pos + length;
2332
- const message = createBaseWaitForFlowResponse();
2409
+ const message = createBaseFlowResult();
2333
2410
  while (reader.pos < end) {
2334
2411
  const tag = reader.uint32();
2335
2412
  switch (tag >>> 3) {
@@ -2370,10 +2447,10 @@ export const WaitForFlowResponse = {
2370
2447
  return message;
2371
2448
  },
2372
2449
  create(base) {
2373
- return WaitForFlowResponse.fromPartial(base ?? {});
2450
+ return FlowResult.fromPartial(base ?? {});
2374
2451
  },
2375
2452
  fromPartial(object) {
2376
- const message = createBaseWaitForFlowResponse();
2453
+ const message = createBaseFlowResult();
2377
2454
  message.flowStatus = object.flowStatus ?? 0;
2378
2455
  message.results = object.results?.map((e) => StepCompletionOutput.fromPartial(e)) || [];
2379
2456
  message.errorType = object.errorType ?? 0;
@@ -3313,6 +3390,15 @@ export const FlowHistoryEvent = {
3313
3390
  case "channelExternalPublish":
3314
3391
  ChannelExternalPublishEvent.encode(message.payload.value, writer.uint32(218).fork()).join();
3315
3392
  break;
3393
+ case "stepWaitForPending":
3394
+ StepMethodPendingEvent.encode(message.payload.value, writer.uint32(226).fork()).join();
3395
+ break;
3396
+ case "stepExecutePending":
3397
+ StepMethodPendingEvent.encode(message.payload.value, writer.uint32(234).fork()).join();
3398
+ break;
3399
+ case "timeTravelFork":
3400
+ TimeTravelForkHistoryEvent.encode(message.payload.value, writer.uint32(242).fork()).join();
3401
+ break;
3316
3402
  }
3317
3403
  return writer;
3318
3404
  },
@@ -3414,6 +3500,36 @@ export const FlowHistoryEvent = {
3414
3500
  };
3415
3501
  continue;
3416
3502
  }
3503
+ case 28: {
3504
+ if (tag !== 226) {
3505
+ break;
3506
+ }
3507
+ message.payload = {
3508
+ $case: "stepWaitForPending",
3509
+ value: StepMethodPendingEvent.decode(reader, reader.uint32()),
3510
+ };
3511
+ continue;
3512
+ }
3513
+ case 29: {
3514
+ if (tag !== 234) {
3515
+ break;
3516
+ }
3517
+ message.payload = {
3518
+ $case: "stepExecutePending",
3519
+ value: StepMethodPendingEvent.decode(reader, reader.uint32()),
3520
+ };
3521
+ continue;
3522
+ }
3523
+ case 30: {
3524
+ if (tag !== 242) {
3525
+ break;
3526
+ }
3527
+ message.payload = {
3528
+ $case: "timeTravelFork",
3529
+ value: TimeTravelForkHistoryEvent.decode(reader, reader.uint32()),
3530
+ };
3531
+ continue;
3532
+ }
3417
3533
  }
3418
3534
  if ((tag & 7) === 4 || tag === 0) {
3419
3535
  break;
@@ -3499,9 +3615,77 @@ export const FlowHistoryEvent = {
3499
3615
  }
3500
3616
  break;
3501
3617
  }
3618
+ case "stepWaitForPending": {
3619
+ if (object.payload?.value !== undefined && object.payload?.value !== null) {
3620
+ message.payload = {
3621
+ $case: "stepWaitForPending",
3622
+ value: StepMethodPendingEvent.fromPartial(object.payload.value),
3623
+ };
3624
+ }
3625
+ break;
3626
+ }
3627
+ case "stepExecutePending": {
3628
+ if (object.payload?.value !== undefined && object.payload?.value !== null) {
3629
+ message.payload = {
3630
+ $case: "stepExecutePending",
3631
+ value: StepMethodPendingEvent.fromPartial(object.payload.value),
3632
+ };
3633
+ }
3634
+ break;
3635
+ }
3636
+ case "timeTravelFork": {
3637
+ if (object.payload?.value !== undefined && object.payload?.value !== null) {
3638
+ message.payload = {
3639
+ $case: "timeTravelFork",
3640
+ value: TimeTravelForkHistoryEvent.fromPartial(object.payload.value),
3641
+ };
3642
+ }
3643
+ break;
3644
+ }
3645
+ }
3646
+ return message;
3647
+ },
3648
+ };
3649
+ function createBaseTimeTravelForkHistoryEvent() {
3650
+ return { previousRunId: "" };
3651
+ }
3652
+ export const TimeTravelForkHistoryEvent = {
3653
+ encode(message, writer = new BinaryWriter()) {
3654
+ if (message.previousRunId !== "") {
3655
+ writer.uint32(10).string(message.previousRunId);
3656
+ }
3657
+ return writer;
3658
+ },
3659
+ decode(input, length) {
3660
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
3661
+ const end = length === undefined ? reader.len : reader.pos + length;
3662
+ const message = createBaseTimeTravelForkHistoryEvent();
3663
+ while (reader.pos < end) {
3664
+ const tag = reader.uint32();
3665
+ switch (tag >>> 3) {
3666
+ case 1: {
3667
+ if (tag !== 10) {
3668
+ break;
3669
+ }
3670
+ message.previousRunId = reader.string();
3671
+ continue;
3672
+ }
3673
+ }
3674
+ if ((tag & 7) === 4 || tag === 0) {
3675
+ break;
3676
+ }
3677
+ reader.skip(tag & 7);
3502
3678
  }
3503
3679
  return message;
3504
3680
  },
3681
+ create(base) {
3682
+ return TimeTravelForkHistoryEvent.fromPartial(base ?? {});
3683
+ },
3684
+ fromPartial(object) {
3685
+ const message = createBaseTimeTravelForkHistoryEvent();
3686
+ message.previousRunId = object.previousRunId ?? "";
3687
+ return message;
3688
+ },
3505
3689
  };
3506
3690
  function createBaseFlowStartedOrContinuedHistoryEvent() {
3507
3691
  return {
@@ -3509,6 +3693,7 @@ function createBaseFlowStartedOrContinuedHistoryEvent() {
3509
3693
  flowType: "",
3510
3694
  flowConfig: undefined,
3511
3695
  flowTimeout: undefined,
3696
+ flowTimeoutPolicy: 0,
3512
3697
  startOrContinue: undefined,
3513
3698
  };
3514
3699
  }
@@ -3526,6 +3711,9 @@ export const FlowStartedOrContinuedHistoryEvent = {
3526
3711
  if (message.flowTimeout !== undefined) {
3527
3712
  Duration.encode(message.flowTimeout, writer.uint32(34).fork()).join();
3528
3713
  }
3714
+ if (message.flowTimeoutPolicy !== 0) {
3715
+ writer.uint32(40).int32(message.flowTimeoutPolicy);
3716
+ }
3529
3717
  switch (message.startOrContinue?.$case) {
3530
3718
  case "initialStart":
3531
3719
  FlowInitialStart.encode(message.startOrContinue.value, writer.uint32(82).fork()).join();
@@ -3571,6 +3759,13 @@ export const FlowStartedOrContinuedHistoryEvent = {
3571
3759
  message.flowTimeout = Duration.decode(reader, reader.uint32());
3572
3760
  continue;
3573
3761
  }
3762
+ case 5: {
3763
+ if (tag !== 40) {
3764
+ break;
3765
+ }
3766
+ message.flowTimeoutPolicy = reader.int32();
3767
+ continue;
3768
+ }
3574
3769
  case 10: {
3575
3770
  if (tag !== 82) {
3576
3771
  break;
@@ -3611,6 +3806,7 @@ export const FlowStartedOrContinuedHistoryEvent = {
3611
3806
  message.flowTimeout = (object.flowTimeout !== undefined && object.flowTimeout !== null)
3612
3807
  ? Duration.fromPartial(object.flowTimeout)
3613
3808
  : undefined;
3809
+ message.flowTimeoutPolicy = object.flowTimeoutPolicy ?? 0;
3614
3810
  switch (object.startOrContinue?.$case) {
3615
3811
  case "initialStart": {
3616
3812
  if (object.startOrContinue?.value !== undefined && object.startOrContinue?.value !== null) {
@@ -3964,6 +4160,73 @@ export const FlowClosedHistoryEvent = {
3964
4160
  return message;
3965
4161
  },
3966
4162
  };
4163
+ function createBaseStepMethodPendingEvent() {
4164
+ return { input: undefined, context: undefined, phase: 0 };
4165
+ }
4166
+ export const StepMethodPendingEvent = {
4167
+ encode(message, writer = new BinaryWriter()) {
4168
+ if (message.input !== undefined) {
4169
+ StepMethodEventInput.encode(message.input, writer.uint32(10).fork()).join();
4170
+ }
4171
+ if (message.context !== undefined) {
4172
+ StepMethodEventContext.encode(message.context, writer.uint32(18).fork()).join();
4173
+ }
4174
+ if (message.phase !== 0) {
4175
+ writer.uint32(24).int32(message.phase);
4176
+ }
4177
+ return writer;
4178
+ },
4179
+ decode(input, length) {
4180
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
4181
+ const end = length === undefined ? reader.len : reader.pos + length;
4182
+ const message = createBaseStepMethodPendingEvent();
4183
+ while (reader.pos < end) {
4184
+ const tag = reader.uint32();
4185
+ switch (tag >>> 3) {
4186
+ case 1: {
4187
+ if (tag !== 10) {
4188
+ break;
4189
+ }
4190
+ message.input = StepMethodEventInput.decode(reader, reader.uint32());
4191
+ continue;
4192
+ }
4193
+ case 2: {
4194
+ if (tag !== 18) {
4195
+ break;
4196
+ }
4197
+ message.context = StepMethodEventContext.decode(reader, reader.uint32());
4198
+ continue;
4199
+ }
4200
+ case 3: {
4201
+ if (tag !== 24) {
4202
+ break;
4203
+ }
4204
+ message.phase = reader.int32();
4205
+ continue;
4206
+ }
4207
+ }
4208
+ if ((tag & 7) === 4 || tag === 0) {
4209
+ break;
4210
+ }
4211
+ reader.skip(tag & 7);
4212
+ }
4213
+ return message;
4214
+ },
4215
+ create(base) {
4216
+ return StepMethodPendingEvent.fromPartial(base ?? {});
4217
+ },
4218
+ fromPartial(object) {
4219
+ const message = createBaseStepMethodPendingEvent();
4220
+ message.input = (object.input !== undefined && object.input !== null)
4221
+ ? StepMethodEventInput.fromPartial(object.input)
4222
+ : undefined;
4223
+ message.context = (object.context !== undefined && object.context !== null)
4224
+ ? StepMethodEventContext.fromPartial(object.context)
4225
+ : undefined;
4226
+ message.phase = object.phase ?? 0;
4227
+ return message;
4228
+ },
4229
+ };
3967
4230
  function createBaseStepMethodFailure() {
3968
4231
  return { backendError: "", details: undefined, attempt: 0 };
3969
4232
  }
@@ -3973,10 +4236,10 @@ export const StepMethodFailure = {
3973
4236
  writer.uint32(10).string(message.backendError);
3974
4237
  }
3975
4238
  if (message.details !== undefined) {
3976
- ErrorResponse.encode(message.details, writer.uint32(42).fork()).join();
4239
+ ServiceErrorResponse.encode(message.details, writer.uint32(18).fork()).join();
3977
4240
  }
3978
4241
  if (message.attempt !== 0) {
3979
- writer.uint32(48).int32(message.attempt);
4242
+ writer.uint32(24).int32(message.attempt);
3980
4243
  }
3981
4244
  return writer;
3982
4245
  },
@@ -3994,15 +4257,15 @@ export const StepMethodFailure = {
3994
4257
  message.backendError = reader.string();
3995
4258
  continue;
3996
4259
  }
3997
- case 5: {
3998
- if (tag !== 42) {
4260
+ case 2: {
4261
+ if (tag !== 18) {
3999
4262
  break;
4000
4263
  }
4001
- message.details = ErrorResponse.decode(reader, reader.uint32());
4264
+ message.details = ServiceErrorResponse.decode(reader, reader.uint32());
4002
4265
  continue;
4003
4266
  }
4004
- case 6: {
4005
- if (tag !== 48) {
4267
+ case 3: {
4268
+ if (tag !== 24) {
4006
4269
  break;
4007
4270
  }
4008
4271
  message.attempt = reader.int32();
@@ -4023,14 +4286,14 @@ export const StepMethodFailure = {
4023
4286
  const message = createBaseStepMethodFailure();
4024
4287
  message.backendError = object.backendError ?? "";
4025
4288
  message.details = (object.details !== undefined && object.details !== null)
4026
- ? ErrorResponse.fromPartial(object.details)
4289
+ ? ServiceErrorResponse.fromPartial(object.details)
4027
4290
  : undefined;
4028
4291
  message.attempt = object.attempt ?? 0;
4029
4292
  return message;
4030
4293
  },
4031
4294
  };
4032
4295
  function createBaseStepMethodOptions() {
4033
- return { timeoutSeconds: 0, retryPolicy: undefined };
4296
+ return { timeoutSeconds: 0, retryPolicy: undefined, heartbeatTimeoutSeconds: 0 };
4034
4297
  }
4035
4298
  export const StepMethodOptions = {
4036
4299
  encode(message, writer = new BinaryWriter()) {
@@ -4040,6 +4303,9 @@ export const StepMethodOptions = {
4040
4303
  if (message.retryPolicy !== undefined) {
4041
4304
  RetryPolicy.encode(message.retryPolicy, writer.uint32(18).fork()).join();
4042
4305
  }
4306
+ if (message.heartbeatTimeoutSeconds !== 0) {
4307
+ writer.uint32(24).int32(message.heartbeatTimeoutSeconds);
4308
+ }
4043
4309
  return writer;
4044
4310
  },
4045
4311
  decode(input, length) {
@@ -4063,6 +4329,13 @@ export const StepMethodOptions = {
4063
4329
  message.retryPolicy = RetryPolicy.decode(reader, reader.uint32());
4064
4330
  continue;
4065
4331
  }
4332
+ case 3: {
4333
+ if (tag !== 24) {
4334
+ break;
4335
+ }
4336
+ message.heartbeatTimeoutSeconds = reader.int32();
4337
+ continue;
4338
+ }
4066
4339
  }
4067
4340
  if ((tag & 7) === 4 || tag === 0) {
4068
4341
  break;
@@ -4080,6 +4353,7 @@ export const StepMethodOptions = {
4080
4353
  message.retryPolicy = (object.retryPolicy !== undefined && object.retryPolicy !== null)
4081
4354
  ? RetryPolicy.fromPartial(object.retryPolicy)
4082
4355
  : undefined;
4356
+ message.heartbeatTimeoutSeconds = object.heartbeatTimeoutSeconds ?? 0;
4083
4357
  return message;
4084
4358
  },
4085
4359
  };
@@ -4188,7 +4462,6 @@ function createBaseStepMethodEventContext() {
4188
4462
  startedTime: undefined,
4189
4463
  duration: undefined,
4190
4464
  methodOptions: undefined,
4191
- isTransientStep: undefined,
4192
4465
  lastFailureInfo: undefined,
4193
4466
  };
4194
4467
  }
@@ -4218,11 +4491,8 @@ export const StepMethodEventContext = {
4218
4491
  if (message.methodOptions !== undefined) {
4219
4492
  StepMethodOptions.encode(message.methodOptions, writer.uint32(66).fork()).join();
4220
4493
  }
4221
- if (message.isTransientStep !== undefined) {
4222
- writer.uint32(72).bool(message.isTransientStep);
4223
- }
4224
4494
  if (message.lastFailureInfo !== undefined) {
4225
- StepMethodFailure.encode(message.lastFailureInfo, writer.uint32(82).fork()).join();
4495
+ StepMethodFailure.encode(message.lastFailureInfo, writer.uint32(74).fork()).join();
4226
4496
  }
4227
4497
  return writer;
4228
4498
  },
@@ -4290,14 +4560,7 @@ export const StepMethodEventContext = {
4290
4560
  continue;
4291
4561
  }
4292
4562
  case 9: {
4293
- if (tag !== 72) {
4294
- break;
4295
- }
4296
- message.isTransientStep = reader.bool();
4297
- continue;
4298
- }
4299
- case 10: {
4300
- if (tag !== 82) {
4563
+ if (tag !== 74) {
4301
4564
  break;
4302
4565
  }
4303
4566
  message.lastFailureInfo = StepMethodFailure.decode(reader, reader.uint32());
@@ -4328,7 +4591,6 @@ export const StepMethodEventContext = {
4328
4591
  message.methodOptions = (object.methodOptions !== undefined && object.methodOptions !== null)
4329
4592
  ? StepMethodOptions.fromPartial(object.methodOptions)
4330
4593
  : undefined;
4331
- message.isTransientStep = object.isTransientStep ?? undefined;
4332
4594
  message.lastFailureInfo = (object.lastFailureInfo !== undefined && object.lastFailureInfo !== null)
4333
4595
  ? StepMethodFailure.fromPartial(object.lastFailureInfo)
4334
4596
  : undefined;
@@ -4342,7 +4604,6 @@ function createBaseStepWaitForCompletedOutput() {
4342
4604
  publishToChannel: [],
4343
4605
  recordEvents: [],
4344
4606
  upsertStepExecutionLocals: [],
4345
- transientStepMovement: undefined,
4346
4607
  };
4347
4608
  }
4348
4609
  export const StepWaitForCompletedOutput = {
@@ -4362,9 +4623,6 @@ export const StepWaitForCompletedOutput = {
4362
4623
  for (const v of message.upsertStepExecutionLocals) {
4363
4624
  KV.encode(v, writer.uint32(42).fork()).join();
4364
4625
  }
4365
- if (message.transientStepMovement !== undefined) {
4366
- StepMovement.encode(message.transientStepMovement, writer.uint32(50).fork()).join();
4367
- }
4368
4626
  return writer;
4369
4627
  },
4370
4628
  decode(input, length) {
@@ -4409,13 +4667,6 @@ export const StepWaitForCompletedOutput = {
4409
4667
  message.upsertStepExecutionLocals.push(KV.decode(reader, reader.uint32()));
4410
4668
  continue;
4411
4669
  }
4412
- case 6: {
4413
- if (tag !== 50) {
4414
- break;
4415
- }
4416
- message.transientStepMovement = StepMovement.decode(reader, reader.uint32());
4417
- continue;
4418
- }
4419
4670
  }
4420
4671
  if ((tag & 7) === 4 || tag === 0) {
4421
4672
  break;
@@ -4436,10 +4687,6 @@ export const StepWaitForCompletedOutput = {
4436
4687
  message.publishToChannel = object.publishToChannel?.map((e) => ChannelMessage.fromPartial(e)) || [];
4437
4688
  message.recordEvents = object.recordEvents?.map((e) => KV.fromPartial(e)) || [];
4438
4689
  message.upsertStepExecutionLocals = object.upsertStepExecutionLocals?.map((e) => KV.fromPartial(e)) || [];
4439
- message.transientStepMovement =
4440
- (object.transientStepMovement !== undefined && object.transientStepMovement !== null)
4441
- ? StepMovement.fromPartial(object.transientStepMovement)
4442
- : undefined;
4443
4690
  return message;
4444
4691
  },
4445
4692
  };
@@ -4864,6 +5111,7 @@ function createBaseRpcExecutionCompletedEvent() {
4864
5111
  upsertAttributes: [],
4865
5112
  recordEvents: [],
4866
5113
  publishToChannel: [],
5114
+ isSetAttributeApi: false,
4867
5115
  };
4868
5116
  }
4869
5117
  export const RpcExecutionCompletedEvent = {
@@ -4889,6 +5137,9 @@ export const RpcExecutionCompletedEvent = {
4889
5137
  for (const v of message.publishToChannel) {
4890
5138
  ChannelMessage.encode(v, writer.uint32(58).fork()).join();
4891
5139
  }
5140
+ if (message.isSetAttributeApi !== false) {
5141
+ writer.uint32(64).bool(message.isSetAttributeApi);
5142
+ }
4892
5143
  return writer;
4893
5144
  },
4894
5145
  decode(input, length) {
@@ -4947,6 +5198,13 @@ export const RpcExecutionCompletedEvent = {
4947
5198
  message.publishToChannel.push(ChannelMessage.decode(reader, reader.uint32()));
4948
5199
  continue;
4949
5200
  }
5201
+ case 8: {
5202
+ if (tag !== 64) {
5203
+ break;
5204
+ }
5205
+ message.isSetAttributeApi = reader.bool();
5206
+ continue;
5207
+ }
4950
5208
  }
4951
5209
  if ((tag & 7) === 4 || tag === 0) {
4952
5210
  break;
@@ -4971,6 +5229,7 @@ export const RpcExecutionCompletedEvent = {
4971
5229
  message.upsertAttributes = object.upsertAttributes?.map((e) => AttributeWrite.fromPartial(e)) || [];
4972
5230
  message.recordEvents = object.recordEvents?.map((e) => KV.fromPartial(e)) || [];
4973
5231
  message.publishToChannel = object.publishToChannel?.map((e) => ChannelMessage.fromPartial(e)) || [];
5232
+ message.isSetAttributeApi = object.isSetAttributeApi ?? false;
4974
5233
  return message;
4975
5234
  },
4976
5235
  };
@@ -5184,7 +5443,7 @@ export const ActiveStepExecutionState = {
5184
5443
  StepMovement.encode(message.movement, writer.uint32(42).fork()).join();
5185
5444
  }
5186
5445
  if (message.waitingCondition !== undefined) {
5187
- WaitingCondition.encode(message.waitingCondition, writer.uint32(50).fork()).join();
5446
+ WaitingConditionState.encode(message.waitingCondition, writer.uint32(50).fork()).join();
5188
5447
  }
5189
5448
  if (message.completedConditions !== undefined) {
5190
5449
  StepExecutionCompletedConditions.encode(message.completedConditions, writer.uint32(58).fork()).join();
@@ -5246,7 +5505,7 @@ export const ActiveStepExecutionState = {
5246
5505
  if (tag !== 50) {
5247
5506
  break;
5248
5507
  }
5249
- message.waitingCondition = WaitingCondition.decode(reader, reader.uint32());
5508
+ message.waitingCondition = WaitingConditionState.decode(reader, reader.uint32());
5250
5509
  continue;
5251
5510
  }
5252
5511
  case 7: {
@@ -5298,7 +5557,7 @@ export const ActiveStepExecutionState = {
5298
5557
  ? StepMovement.fromPartial(object.movement)
5299
5558
  : undefined;
5300
5559
  message.waitingCondition = (object.waitingCondition !== undefined && object.waitingCondition !== null)
5301
- ? WaitingCondition.fromPartial(object.waitingCondition)
5560
+ ? WaitingConditionState.fromPartial(object.waitingCondition)
5302
5561
  : undefined;
5303
5562
  message.completedConditions = (object.completedConditions !== undefined && object.completedConditions !== null)
5304
5563
  ? StepExecutionCompletedConditions.fromPartial(object.completedConditions)
@@ -5538,13 +5797,12 @@ function createBaseResetFlowRequest() {
5538
5797
  flowId: "",
5539
5798
  runId: "",
5540
5799
  resetType: 0,
5541
- historyEventId: 0,
5542
5800
  reason: "",
5543
5801
  historyEventTime: "",
5544
5802
  stepType: "",
5545
5803
  stepExecutionId: "",
5546
- skipChannelMessagesReapply: false,
5547
- skipLockingRpcReapply: false,
5804
+ skipWritesReapply: false,
5805
+ stepMethod: 0,
5548
5806
  };
5549
5807
  }
5550
5808
  export const ResetFlowRequest = {
@@ -5558,26 +5816,23 @@ export const ResetFlowRequest = {
5558
5816
  if (message.resetType !== 0) {
5559
5817
  writer.uint32(24).int32(message.resetType);
5560
5818
  }
5561
- if (message.historyEventId !== 0) {
5562
- writer.uint32(32).int32(message.historyEventId);
5563
- }
5564
5819
  if (message.reason !== "") {
5565
- writer.uint32(42).string(message.reason);
5820
+ writer.uint32(34).string(message.reason);
5566
5821
  }
5567
5822
  if (message.historyEventTime !== "") {
5568
- writer.uint32(50).string(message.historyEventTime);
5823
+ writer.uint32(42).string(message.historyEventTime);
5569
5824
  }
5570
5825
  if (message.stepType !== "") {
5571
- writer.uint32(58).string(message.stepType);
5826
+ writer.uint32(50).string(message.stepType);
5572
5827
  }
5573
5828
  if (message.stepExecutionId !== "") {
5574
- writer.uint32(66).string(message.stepExecutionId);
5829
+ writer.uint32(58).string(message.stepExecutionId);
5575
5830
  }
5576
- if (message.skipChannelMessagesReapply !== false) {
5577
- writer.uint32(72).bool(message.skipChannelMessagesReapply);
5831
+ if (message.skipWritesReapply !== false) {
5832
+ writer.uint32(64).bool(message.skipWritesReapply);
5578
5833
  }
5579
- if (message.skipLockingRpcReapply !== false) {
5580
- writer.uint32(80).bool(message.skipLockingRpcReapply);
5834
+ if (message.stepMethod !== 0) {
5835
+ writer.uint32(72).int32(message.stepMethod);
5581
5836
  }
5582
5837
  return writer;
5583
5838
  },
@@ -5610,52 +5865,45 @@ export const ResetFlowRequest = {
5610
5865
  continue;
5611
5866
  }
5612
5867
  case 4: {
5613
- if (tag !== 32) {
5868
+ if (tag !== 34) {
5614
5869
  break;
5615
5870
  }
5616
- message.historyEventId = reader.int32();
5871
+ message.reason = reader.string();
5617
5872
  continue;
5618
5873
  }
5619
5874
  case 5: {
5620
5875
  if (tag !== 42) {
5621
5876
  break;
5622
5877
  }
5623
- message.reason = reader.string();
5878
+ message.historyEventTime = reader.string();
5624
5879
  continue;
5625
5880
  }
5626
5881
  case 6: {
5627
5882
  if (tag !== 50) {
5628
5883
  break;
5629
5884
  }
5630
- message.historyEventTime = reader.string();
5885
+ message.stepType = reader.string();
5631
5886
  continue;
5632
5887
  }
5633
5888
  case 7: {
5634
5889
  if (tag !== 58) {
5635
5890
  break;
5636
5891
  }
5637
- message.stepType = reader.string();
5892
+ message.stepExecutionId = reader.string();
5638
5893
  continue;
5639
5894
  }
5640
5895
  case 8: {
5641
- if (tag !== 66) {
5896
+ if (tag !== 64) {
5642
5897
  break;
5643
5898
  }
5644
- message.stepExecutionId = reader.string();
5899
+ message.skipWritesReapply = reader.bool();
5645
5900
  continue;
5646
5901
  }
5647
5902
  case 9: {
5648
5903
  if (tag !== 72) {
5649
5904
  break;
5650
5905
  }
5651
- message.skipChannelMessagesReapply = reader.bool();
5652
- continue;
5653
- }
5654
- case 10: {
5655
- if (tag !== 80) {
5656
- break;
5657
- }
5658
- message.skipLockingRpcReapply = reader.bool();
5906
+ message.stepMethod = reader.int32();
5659
5907
  continue;
5660
5908
  }
5661
5909
  }
@@ -5674,13 +5922,12 @@ export const ResetFlowRequest = {
5674
5922
  message.flowId = object.flowId ?? "";
5675
5923
  message.runId = object.runId ?? "";
5676
5924
  message.resetType = object.resetType ?? 0;
5677
- message.historyEventId = object.historyEventId ?? 0;
5678
5925
  message.reason = object.reason ?? "";
5679
5926
  message.historyEventTime = object.historyEventTime ?? "";
5680
5927
  message.stepType = object.stepType ?? "";
5681
5928
  message.stepExecutionId = object.stepExecutionId ?? "";
5682
- message.skipChannelMessagesReapply = object.skipChannelMessagesReapply ?? false;
5683
- message.skipLockingRpcReapply = object.skipLockingRpcReapply ?? false;
5929
+ message.skipWritesReapply = object.skipWritesReapply ?? false;
5930
+ message.stepMethod = object.stepMethod ?? 0;
5684
5931
  return message;
5685
5932
  },
5686
5933
  };
@@ -6452,7 +6699,7 @@ export const HealthInfo = {
6452
6699
  return message;
6453
6700
  },
6454
6701
  };
6455
- function createBaseErrorResponse() {
6702
+ function createBaseServiceErrorResponse() {
6456
6703
  return {
6457
6704
  detail: "",
6458
6705
  subStatus: 0,
@@ -6462,7 +6709,7 @@ function createBaseErrorResponse() {
6462
6709
  originalWorkerErrorStackTrace: "",
6463
6710
  };
6464
6711
  }
6465
- export const ErrorResponse = {
6712
+ export const ServiceErrorResponse = {
6466
6713
  encode(message, writer = new BinaryWriter()) {
6467
6714
  if (message.detail !== "") {
6468
6715
  writer.uint32(10).string(message.detail);
@@ -6487,7 +6734,7 @@ export const ErrorResponse = {
6487
6734
  decode(input, length) {
6488
6735
  const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
6489
6736
  const end = length === undefined ? reader.len : reader.pos + length;
6490
- const message = createBaseErrorResponse();
6737
+ const message = createBaseServiceErrorResponse();
6491
6738
  while (reader.pos < end) {
6492
6739
  const tag = reader.uint32();
6493
6740
  switch (tag >>> 3) {
@@ -6542,10 +6789,10 @@ export const ErrorResponse = {
6542
6789
  return message;
6543
6790
  },
6544
6791
  create(base) {
6545
- return ErrorResponse.fromPartial(base ?? {});
6792
+ return ServiceErrorResponse.fromPartial(base ?? {});
6546
6793
  },
6547
6794
  fromPartial(object) {
6548
- const message = createBaseErrorResponse();
6795
+ const message = createBaseServiceErrorResponse();
6549
6796
  message.detail = object.detail ?? "";
6550
6797
  message.subStatus = object.subStatus ?? 0;
6551
6798
  message.originalWorkerErrorDetail = object.originalWorkerErrorDetail ?? "";
@@ -6556,7 +6803,7 @@ export const ErrorResponse = {
6556
6803
  },
6557
6804
  };
6558
6805
  function createBaseWorkerErrorResponse() {
6559
- return { detail: "", errorType: "", stackTrace: "" };
6806
+ return { detail: "", errorType: "", stackTrace: "", retryAfterSeconds: 0 };
6560
6807
  }
6561
6808
  export const WorkerErrorResponse = {
6562
6809
  encode(message, writer = new BinaryWriter()) {
@@ -6569,6 +6816,9 @@ export const WorkerErrorResponse = {
6569
6816
  if (message.stackTrace !== "") {
6570
6817
  writer.uint32(26).string(message.stackTrace);
6571
6818
  }
6819
+ if (message.retryAfterSeconds !== 0) {
6820
+ writer.uint32(32).int32(message.retryAfterSeconds);
6821
+ }
6572
6822
  return writer;
6573
6823
  },
6574
6824
  decode(input, length) {
@@ -6599,6 +6849,13 @@ export const WorkerErrorResponse = {
6599
6849
  message.stackTrace = reader.string();
6600
6850
  continue;
6601
6851
  }
6852
+ case 4: {
6853
+ if (tag !== 32) {
6854
+ break;
6855
+ }
6856
+ message.retryAfterSeconds = reader.int32();
6857
+ continue;
6858
+ }
6602
6859
  }
6603
6860
  if ((tag & 7) === 4 || tag === 0) {
6604
6861
  break;
@@ -6615,31 +6872,52 @@ export const WorkerErrorResponse = {
6615
6872
  message.detail = object.detail ?? "";
6616
6873
  message.errorType = object.errorType ?? "";
6617
6874
  message.stackTrace = object.stackTrace ?? "";
6875
+ message.retryAfterSeconds = object.retryAfterSeconds ?? 0;
6618
6876
  return message;
6619
6877
  },
6620
6878
  };
6621
- function createBaseChannelInfo() {
6622
- return { size: 0 };
6879
+ function createBaseInternalActivityError() {
6880
+ return { serverDetail: "", workerGrpcStatus: 0, workerError: undefined };
6623
6881
  }
6624
- export const ChannelInfo = {
6882
+ export const InternalActivityError = {
6625
6883
  encode(message, writer = new BinaryWriter()) {
6626
- if (message.size !== 0) {
6627
- writer.uint32(8).int32(message.size);
6884
+ if (message.serverDetail !== "") {
6885
+ writer.uint32(10).string(message.serverDetail);
6886
+ }
6887
+ if (message.workerGrpcStatus !== 0) {
6888
+ writer.uint32(16).int32(message.workerGrpcStatus);
6889
+ }
6890
+ if (message.workerError !== undefined) {
6891
+ InternalWorkerError.encode(message.workerError, writer.uint32(26).fork()).join();
6628
6892
  }
6629
6893
  return writer;
6630
6894
  },
6631
6895
  decode(input, length) {
6632
6896
  const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
6633
6897
  const end = length === undefined ? reader.len : reader.pos + length;
6634
- const message = createBaseChannelInfo();
6898
+ const message = createBaseInternalActivityError();
6635
6899
  while (reader.pos < end) {
6636
6900
  const tag = reader.uint32();
6637
6901
  switch (tag >>> 3) {
6638
6902
  case 1: {
6639
- if (tag !== 8) {
6903
+ if (tag !== 10) {
6640
6904
  break;
6641
6905
  }
6642
- message.size = reader.int32();
6906
+ message.serverDetail = reader.string();
6907
+ continue;
6908
+ }
6909
+ case 2: {
6910
+ if (tag !== 16) {
6911
+ break;
6912
+ }
6913
+ message.workerGrpcStatus = reader.int32();
6914
+ continue;
6915
+ }
6916
+ case 3: {
6917
+ if (tag !== 26) {
6918
+ break;
6919
+ }
6920
+ message.workerError = InternalWorkerError.decode(reader, reader.uint32());
6643
6921
  continue;
6644
6922
  }
6645
6923
  }
@@ -6651,11 +6929,185 @@ export const ChannelInfo = {
6651
6929
  return message;
6652
6930
  },
6653
6931
  create(base) {
6654
- return ChannelInfo.fromPartial(base ?? {});
6932
+ return InternalActivityError.fromPartial(base ?? {});
6655
6933
  },
6656
6934
  fromPartial(object) {
6657
- const message = createBaseChannelInfo();
6658
- message.size = object.size ?? 0;
6935
+ const message = createBaseInternalActivityError();
6936
+ message.serverDetail = object.serverDetail ?? "";
6937
+ message.workerGrpcStatus = object.workerGrpcStatus ?? 0;
6938
+ message.workerError = (object.workerError !== undefined && object.workerError !== null)
6939
+ ? InternalWorkerError.fromPartial(object.workerError)
6940
+ : undefined;
6941
+ return message;
6942
+ },
6943
+ };
6944
+ function createBaseInternalWorkerError() {
6945
+ return { detail: "", errorType: "", stackTrace: "" };
6946
+ }
6947
+ export const InternalWorkerError = {
6948
+ encode(message, writer = new BinaryWriter()) {
6949
+ if (message.detail !== "") {
6950
+ writer.uint32(10).string(message.detail);
6951
+ }
6952
+ if (message.errorType !== "") {
6953
+ writer.uint32(18).string(message.errorType);
6954
+ }
6955
+ if (message.stackTrace !== "") {
6956
+ writer.uint32(26).string(message.stackTrace);
6957
+ }
6958
+ return writer;
6959
+ },
6960
+ decode(input, length) {
6961
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
6962
+ const end = length === undefined ? reader.len : reader.pos + length;
6963
+ const message = createBaseInternalWorkerError();
6964
+ while (reader.pos < end) {
6965
+ const tag = reader.uint32();
6966
+ switch (tag >>> 3) {
6967
+ case 1: {
6968
+ if (tag !== 10) {
6969
+ break;
6970
+ }
6971
+ message.detail = reader.string();
6972
+ continue;
6973
+ }
6974
+ case 2: {
6975
+ if (tag !== 18) {
6976
+ break;
6977
+ }
6978
+ message.errorType = reader.string();
6979
+ continue;
6980
+ }
6981
+ case 3: {
6982
+ if (tag !== 26) {
6983
+ break;
6984
+ }
6985
+ message.stackTrace = reader.string();
6986
+ continue;
6987
+ }
6988
+ }
6989
+ if ((tag & 7) === 4 || tag === 0) {
6990
+ break;
6991
+ }
6992
+ reader.skip(tag & 7);
6993
+ }
6994
+ return message;
6995
+ },
6996
+ create(base) {
6997
+ return InternalWorkerError.fromPartial(base ?? {});
6998
+ },
6999
+ fromPartial(object) {
7000
+ const message = createBaseInternalWorkerError();
7001
+ message.detail = object.detail ?? "";
7002
+ message.errorType = object.errorType ?? "";
7003
+ message.stackTrace = object.stackTrace ?? "";
7004
+ return message;
7005
+ },
7006
+ };
7007
+ function createBaseInternalFlowError() {
7008
+ return { failure: undefined };
7009
+ }
7010
+ export const InternalFlowError = {
7011
+ encode(message, writer = new BinaryWriter()) {
7012
+ switch (message.failure?.$case) {
7013
+ case "serverDetail":
7014
+ writer.uint32(10).string(message.failure.value);
7015
+ break;
7016
+ case "activityError":
7017
+ InternalActivityError.encode(message.failure.value, writer.uint32(18).fork()).join();
7018
+ break;
7019
+ }
7020
+ return writer;
7021
+ },
7022
+ decode(input, length) {
7023
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
7024
+ const end = length === undefined ? reader.len : reader.pos + length;
7025
+ const message = createBaseInternalFlowError();
7026
+ while (reader.pos < end) {
7027
+ const tag = reader.uint32();
7028
+ switch (tag >>> 3) {
7029
+ case 1: {
7030
+ if (tag !== 10) {
7031
+ break;
7032
+ }
7033
+ message.failure = { $case: "serverDetail", value: reader.string() };
7034
+ continue;
7035
+ }
7036
+ case 2: {
7037
+ if (tag !== 18) {
7038
+ break;
7039
+ }
7040
+ message.failure = { $case: "activityError", value: InternalActivityError.decode(reader, reader.uint32()) };
7041
+ continue;
7042
+ }
7043
+ }
7044
+ if ((tag & 7) === 4 || tag === 0) {
7045
+ break;
7046
+ }
7047
+ reader.skip(tag & 7);
7048
+ }
7049
+ return message;
7050
+ },
7051
+ create(base) {
7052
+ return InternalFlowError.fromPartial(base ?? {});
7053
+ },
7054
+ fromPartial(object) {
7055
+ const message = createBaseInternalFlowError();
7056
+ switch (object.failure?.$case) {
7057
+ case "serverDetail": {
7058
+ if (object.failure?.value !== undefined && object.failure?.value !== null) {
7059
+ message.failure = { $case: "serverDetail", value: object.failure.value };
7060
+ }
7061
+ break;
7062
+ }
7063
+ case "activityError": {
7064
+ if (object.failure?.value !== undefined && object.failure?.value !== null) {
7065
+ message.failure = { $case: "activityError", value: InternalActivityError.fromPartial(object.failure.value) };
7066
+ }
7067
+ break;
7068
+ }
7069
+ }
7070
+ return message;
7071
+ },
7072
+ };
7073
+ function createBaseChannelInfo() {
7074
+ return { size: 0 };
7075
+ }
7076
+ export const ChannelInfo = {
7077
+ encode(message, writer = new BinaryWriter()) {
7078
+ if (message.size !== 0) {
7079
+ writer.uint32(8).int32(message.size);
7080
+ }
7081
+ return writer;
7082
+ },
7083
+ decode(input, length) {
7084
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
7085
+ const end = length === undefined ? reader.len : reader.pos + length;
7086
+ const message = createBaseChannelInfo();
7087
+ while (reader.pos < end) {
7088
+ const tag = reader.uint32();
7089
+ switch (tag >>> 3) {
7090
+ case 1: {
7091
+ if (tag !== 8) {
7092
+ break;
7093
+ }
7094
+ message.size = reader.int32();
7095
+ continue;
7096
+ }
7097
+ }
7098
+ if ((tag & 7) === 4 || tag === 0) {
7099
+ break;
7100
+ }
7101
+ reader.skip(tag & 7);
7102
+ }
7103
+ return message;
7104
+ },
7105
+ create(base) {
7106
+ return ChannelInfo.fromPartial(base ?? {});
7107
+ },
7108
+ fromPartial(object) {
7109
+ const message = createBaseChannelInfo();
7110
+ message.size = object.size ?? 0;
6659
7111
  return message;
6660
7112
  },
6661
7113
  };
@@ -6750,19 +7202,18 @@ export const InvokeWaitForMethodRequest = {
6750
7202
  };
6751
7203
  function createBaseInvokeWaitForMethodResponse() {
6752
7204
  return {
6753
- localActivityInput: undefined,
7205
+ localActivityMetadata: undefined,
6754
7206
  upsertAttributes: [],
6755
7207
  waitingCondition: undefined,
6756
7208
  upsertStepExeLocals: [],
6757
7209
  recordEvents: [],
6758
7210
  publishToChannel: [],
6759
- transientStepMovement: undefined,
6760
7211
  };
6761
7212
  }
6762
7213
  export const InvokeWaitForMethodResponse = {
6763
7214
  encode(message, writer = new BinaryWriter()) {
6764
- if (message.localActivityInput !== undefined) {
6765
- LocalActivityInput.encode(message.localActivityInput, writer.uint32(10).fork()).join();
7215
+ if (message.localActivityMetadata !== undefined) {
7216
+ LocalActivityMetadata.encode(message.localActivityMetadata, writer.uint32(10).fork()).join();
6766
7217
  }
6767
7218
  for (const v of message.upsertAttributes) {
6768
7219
  AttributeWrite.encode(v, writer.uint32(18).fork()).join();
@@ -6779,9 +7230,6 @@ export const InvokeWaitForMethodResponse = {
6779
7230
  for (const v of message.publishToChannel) {
6780
7231
  ChannelMessage.encode(v, writer.uint32(50).fork()).join();
6781
7232
  }
6782
- if (message.transientStepMovement !== undefined) {
6783
- StepMovement.encode(message.transientStepMovement, writer.uint32(58).fork()).join();
6784
- }
6785
7233
  return writer;
6786
7234
  },
6787
7235
  decode(input, length) {
@@ -6795,7 +7243,7 @@ export const InvokeWaitForMethodResponse = {
6795
7243
  if (tag !== 10) {
6796
7244
  break;
6797
7245
  }
6798
- message.localActivityInput = LocalActivityInput.decode(reader, reader.uint32());
7246
+ message.localActivityMetadata = LocalActivityMetadata.decode(reader, reader.uint32());
6799
7247
  continue;
6800
7248
  }
6801
7249
  case 2: {
@@ -6833,13 +7281,6 @@ export const InvokeWaitForMethodResponse = {
6833
7281
  message.publishToChannel.push(ChannelMessage.decode(reader, reader.uint32()));
6834
7282
  continue;
6835
7283
  }
6836
- case 7: {
6837
- if (tag !== 58) {
6838
- break;
6839
- }
6840
- message.transientStepMovement = StepMovement.decode(reader, reader.uint32());
6841
- continue;
6842
- }
6843
7284
  }
6844
7285
  if ((tag & 7) === 4 || tag === 0) {
6845
7286
  break;
@@ -6853,9 +7294,10 @@ export const InvokeWaitForMethodResponse = {
6853
7294
  },
6854
7295
  fromPartial(object) {
6855
7296
  const message = createBaseInvokeWaitForMethodResponse();
6856
- message.localActivityInput = (object.localActivityInput !== undefined && object.localActivityInput !== null)
6857
- ? LocalActivityInput.fromPartial(object.localActivityInput)
6858
- : undefined;
7297
+ message.localActivityMetadata =
7298
+ (object.localActivityMetadata !== undefined && object.localActivityMetadata !== null)
7299
+ ? LocalActivityMetadata.fromPartial(object.localActivityMetadata)
7300
+ : undefined;
6859
7301
  message.upsertAttributes = object.upsertAttributes?.map((e) => AttributeWrite.fromPartial(e)) || [];
6860
7302
  message.waitingCondition = (object.waitingCondition !== undefined && object.waitingCondition !== null)
6861
7303
  ? WaitingCondition.fromPartial(object.waitingCondition)
@@ -6863,10 +7305,6 @@ export const InvokeWaitForMethodResponse = {
6863
7305
  message.upsertStepExeLocals = object.upsertStepExeLocals?.map((e) => KV.fromPartial(e)) || [];
6864
7306
  message.recordEvents = object.recordEvents?.map((e) => KV.fromPartial(e)) || [];
6865
7307
  message.publishToChannel = object.publishToChannel?.map((e) => ChannelMessage.fromPartial(e)) || [];
6866
- message.transientStepMovement =
6867
- (object.transientStepMovement !== undefined && object.transientStepMovement !== null)
6868
- ? StepMovement.fromPartial(object.transientStepMovement)
6869
- : undefined;
6870
7308
  return message;
6871
7309
  },
6872
7310
  };
@@ -6993,7 +7431,7 @@ export const InvokeExecuteMethodRequest = {
6993
7431
  };
6994
7432
  function createBaseInvokeExecuteMethodResponse() {
6995
7433
  return {
6996
- localActivityInput: undefined,
7434
+ localActivityMetadata: undefined,
6997
7435
  stepDecision: undefined,
6998
7436
  upsertAttributes: [],
6999
7437
  recordEvents: [],
@@ -7003,8 +7441,8 @@ function createBaseInvokeExecuteMethodResponse() {
7003
7441
  }
7004
7442
  export const InvokeExecuteMethodResponse = {
7005
7443
  encode(message, writer = new BinaryWriter()) {
7006
- if (message.localActivityInput !== undefined) {
7007
- LocalActivityInput.encode(message.localActivityInput, writer.uint32(10).fork()).join();
7444
+ if (message.localActivityMetadata !== undefined) {
7445
+ LocalActivityMetadata.encode(message.localActivityMetadata, writer.uint32(10).fork()).join();
7008
7446
  }
7009
7447
  if (message.stepDecision !== undefined) {
7010
7448
  StepDecision.encode(message.stepDecision, writer.uint32(18).fork()).join();
@@ -7034,7 +7472,7 @@ export const InvokeExecuteMethodResponse = {
7034
7472
  if (tag !== 10) {
7035
7473
  break;
7036
7474
  }
7037
- message.localActivityInput = LocalActivityInput.decode(reader, reader.uint32());
7475
+ message.localActivityMetadata = LocalActivityMetadata.decode(reader, reader.uint32());
7038
7476
  continue;
7039
7477
  }
7040
7478
  case 2: {
@@ -7085,9 +7523,10 @@ export const InvokeExecuteMethodResponse = {
7085
7523
  },
7086
7524
  fromPartial(object) {
7087
7525
  const message = createBaseInvokeExecuteMethodResponse();
7088
- message.localActivityInput = (object.localActivityInput !== undefined && object.localActivityInput !== null)
7089
- ? LocalActivityInput.fromPartial(object.localActivityInput)
7090
- : undefined;
7526
+ message.localActivityMetadata =
7527
+ (object.localActivityMetadata !== undefined && object.localActivityMetadata !== null)
7528
+ ? LocalActivityMetadata.fromPartial(object.localActivityMetadata)
7529
+ : undefined;
7091
7530
  message.stepDecision = (object.stepDecision !== undefined && object.stepDecision !== null)
7092
7531
  ? StepDecision.fromPartial(object.stepDecision)
7093
7532
  : undefined;
@@ -7348,7 +7787,7 @@ export const InvokeWorkerRPCResponse = {
7348
7787
  },
7349
7788
  };
7350
7789
  function createBaseStepDecision() {
7351
- return { nextSteps: [], closeDecision: undefined };
7790
+ return { nextSteps: [], closeDecision: undefined, cancelStepTypes: [], cancelSiblingStepTypes: [] };
7352
7791
  }
7353
7792
  export const StepDecision = {
7354
7793
  encode(message, writer = new BinaryWriter()) {
@@ -7358,6 +7797,12 @@ export const StepDecision = {
7358
7797
  if (message.closeDecision !== undefined) {
7359
7798
  CloseDecision.encode(message.closeDecision, writer.uint32(18).fork()).join();
7360
7799
  }
7800
+ for (const v of message.cancelStepTypes) {
7801
+ writer.uint32(26).string(v);
7802
+ }
7803
+ for (const v of message.cancelSiblingStepTypes) {
7804
+ writer.uint32(34).string(v);
7805
+ }
7361
7806
  return writer;
7362
7807
  },
7363
7808
  decode(input, length) {
@@ -7381,6 +7826,20 @@ export const StepDecision = {
7381
7826
  message.closeDecision = CloseDecision.decode(reader, reader.uint32());
7382
7827
  continue;
7383
7828
  }
7829
+ case 3: {
7830
+ if (tag !== 26) {
7831
+ break;
7832
+ }
7833
+ message.cancelStepTypes.push(reader.string());
7834
+ continue;
7835
+ }
7836
+ case 4: {
7837
+ if (tag !== 34) {
7838
+ break;
7839
+ }
7840
+ message.cancelSiblingStepTypes.push(reader.string());
7841
+ continue;
7842
+ }
7384
7843
  }
7385
7844
  if ((tag & 7) === 4 || tag === 0) {
7386
7845
  break;
@@ -7398,6 +7857,8 @@ export const StepDecision = {
7398
7857
  message.closeDecision = (object.closeDecision !== undefined && object.closeDecision !== null)
7399
7858
  ? CloseDecision.fromPartial(object.closeDecision)
7400
7859
  : undefined;
7860
+ message.cancelStepTypes = object.cancelStepTypes?.map((e) => e) || [];
7861
+ message.cancelSiblingStepTypes = object.cancelSiblingStepTypes?.map((e) => e) || [];
7401
7862
  return message;
7402
7863
  },
7403
7864
  };
@@ -7467,7 +7928,13 @@ export const CloseDecision = {
7467
7928
  },
7468
7929
  };
7469
7930
  function createBaseStepMovement() {
7470
- return { stepType: "", stepInput: undefined, stepOptions: undefined, fromStepExecutionIdInternalOnly: "" };
7931
+ return {
7932
+ stepType: "",
7933
+ stepInput: undefined,
7934
+ stepOptions: undefined,
7935
+ fromStepExecutionIdInternalOnly: "",
7936
+ recoveryErrorInternalOnly: undefined,
7937
+ };
7471
7938
  }
7472
7939
  export const StepMovement = {
7473
7940
  encode(message, writer = new BinaryWriter()) {
@@ -7483,6 +7950,9 @@ export const StepMovement = {
7483
7950
  if (message.fromStepExecutionIdInternalOnly !== "") {
7484
7951
  writer.uint32(34).string(message.fromStepExecutionIdInternalOnly);
7485
7952
  }
7953
+ if (message.recoveryErrorInternalOnly !== undefined) {
7954
+ RecoveryErrorInfo.encode(message.recoveryErrorInternalOnly, writer.uint32(42).fork()).join();
7955
+ }
7486
7956
  return writer;
7487
7957
  },
7488
7958
  decode(input, length) {
@@ -7520,6 +7990,13 @@ export const StepMovement = {
7520
7990
  message.fromStepExecutionIdInternalOnly = reader.string();
7521
7991
  continue;
7522
7992
  }
7993
+ case 5: {
7994
+ if (tag !== 42) {
7995
+ break;
7996
+ }
7997
+ message.recoveryErrorInternalOnly = RecoveryErrorInfo.decode(reader, reader.uint32());
7998
+ continue;
7999
+ }
7523
8000
  }
7524
8001
  if ((tag & 7) === 4 || tag === 0) {
7525
8002
  break;
@@ -7541,6 +8018,10 @@ export const StepMovement = {
7541
8018
  ? StepOptions.fromPartial(object.stepOptions)
7542
8019
  : undefined;
7543
8020
  message.fromStepExecutionIdInternalOnly = object.fromStepExecutionIdInternalOnly ?? "";
8021
+ message.recoveryErrorInternalOnly =
8022
+ (object.recoveryErrorInternalOnly !== undefined && object.recoveryErrorInternalOnly !== null)
8023
+ ? RecoveryErrorInfo.fromPartial(object.recoveryErrorInternalOnly)
8024
+ : undefined;
7544
8025
  return message;
7545
8026
  },
7546
8027
  };
@@ -7586,7 +8067,13 @@ export const ConditionCombination = {
7586
8067
  },
7587
8068
  };
7588
8069
  function createBaseWaitingCondition() {
7589
- return { waitingConditionType: 0, timerConditions: [], channelConditions: [], conditionCombinations: [] };
8070
+ return {
8071
+ waitingConditionType: 0,
8072
+ timerConditions: [],
8073
+ channelConditions: [],
8074
+ conditionCombinations: [],
8075
+ subFlowConditions: [],
8076
+ };
7590
8077
  }
7591
8078
  export const WaitingCondition = {
7592
8079
  encode(message, writer = new BinaryWriter()) {
@@ -7602,6 +8089,9 @@ export const WaitingCondition = {
7602
8089
  for (const v of message.conditionCombinations) {
7603
8090
  ConditionCombination.encode(v, writer.uint32(34).fork()).join();
7604
8091
  }
8092
+ for (const v of message.subFlowConditions) {
8093
+ SubFlowCondition.encode(v, writer.uint32(42).fork()).join();
8094
+ }
7605
8095
  return writer;
7606
8096
  },
7607
8097
  decode(input, length) {
@@ -7639,6 +8129,13 @@ export const WaitingCondition = {
7639
8129
  message.conditionCombinations.push(ConditionCombination.decode(reader, reader.uint32()));
7640
8130
  continue;
7641
8131
  }
8132
+ case 5: {
8133
+ if (tag !== 42) {
8134
+ break;
8135
+ }
8136
+ message.subFlowConditions.push(SubFlowCondition.decode(reader, reader.uint32()));
8137
+ continue;
8138
+ }
7642
8139
  }
7643
8140
  if ((tag & 7) === 4 || tag === 0) {
7644
8141
  break;
@@ -7656,57 +8153,78 @@ export const WaitingCondition = {
7656
8153
  message.timerConditions = object.timerConditions?.map((e) => TimerCondition.fromPartial(e)) || [];
7657
8154
  message.channelConditions = object.channelConditions?.map((e) => ChannelCondition.fromPartial(e)) || [];
7658
8155
  message.conditionCombinations = object.conditionCombinations?.map((e) => ConditionCombination.fromPartial(e)) || [];
8156
+ message.subFlowConditions = object.subFlowConditions?.map((e) => SubFlowCondition.fromPartial(e)) || [];
7659
8157
  return message;
7660
8158
  },
7661
8159
  };
7662
- function createBaseTimerCondition() {
7663
- return { conditionId: "", durationSeconds: 0n, firingUnixTimestampSeconds: 0n };
8160
+ function createBaseWaitingConditionState() {
8161
+ return {
8162
+ waitingConditionType: 0,
8163
+ timerConditions: [],
8164
+ channelConditions: [],
8165
+ conditionCombinations: [],
8166
+ subFlowConditions: [],
8167
+ };
7664
8168
  }
7665
- export const TimerCondition = {
8169
+ export const WaitingConditionState = {
7666
8170
  encode(message, writer = new BinaryWriter()) {
7667
- if (message.conditionId !== "") {
7668
- writer.uint32(10).string(message.conditionId);
8171
+ if (message.waitingConditionType !== 0) {
8172
+ writer.uint32(8).int32(message.waitingConditionType);
7669
8173
  }
7670
- if (message.durationSeconds !== 0n) {
7671
- if (BigInt.asIntN(64, message.durationSeconds) !== message.durationSeconds) {
7672
- throw new globalThis.Error("value provided for field message.durationSeconds of type int64 too large");
7673
- }
7674
- writer.uint32(16).int64(message.durationSeconds);
8174
+ for (const v of message.timerConditions) {
8175
+ TimerCondition.encode(v, writer.uint32(18).fork()).join();
7675
8176
  }
7676
- if (message.firingUnixTimestampSeconds !== 0n) {
7677
- if (BigInt.asIntN(64, message.firingUnixTimestampSeconds) !== message.firingUnixTimestampSeconds) {
7678
- throw new globalThis.Error("value provided for field message.firingUnixTimestampSeconds of type int64 too large");
7679
- }
7680
- writer.uint32(24).int64(message.firingUnixTimestampSeconds);
8177
+ for (const v of message.channelConditions) {
8178
+ ChannelCondition.encode(v, writer.uint32(26).fork()).join();
8179
+ }
8180
+ for (const v of message.conditionCombinations) {
8181
+ ConditionCombination.encode(v, writer.uint32(34).fork()).join();
8182
+ }
8183
+ for (const v of message.subFlowConditions) {
8184
+ SubFlowConditionState.encode(v, writer.uint32(42).fork()).join();
7681
8185
  }
7682
8186
  return writer;
7683
8187
  },
7684
8188
  decode(input, length) {
7685
8189
  const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
7686
8190
  const end = length === undefined ? reader.len : reader.pos + length;
7687
- const message = createBaseTimerCondition();
8191
+ const message = createBaseWaitingConditionState();
7688
8192
  while (reader.pos < end) {
7689
8193
  const tag = reader.uint32();
7690
8194
  switch (tag >>> 3) {
7691
8195
  case 1: {
7692
- if (tag !== 10) {
8196
+ if (tag !== 8) {
7693
8197
  break;
7694
8198
  }
7695
- message.conditionId = reader.string();
8199
+ message.waitingConditionType = reader.int32();
7696
8200
  continue;
7697
8201
  }
7698
8202
  case 2: {
7699
- if (tag !== 16) {
8203
+ if (tag !== 18) {
7700
8204
  break;
7701
8205
  }
7702
- message.durationSeconds = reader.int64();
8206
+ message.timerConditions.push(TimerCondition.decode(reader, reader.uint32()));
7703
8207
  continue;
7704
8208
  }
7705
8209
  case 3: {
7706
- if (tag !== 24) {
8210
+ if (tag !== 26) {
7707
8211
  break;
7708
8212
  }
7709
- message.firingUnixTimestampSeconds = reader.int64();
8213
+ message.channelConditions.push(ChannelCondition.decode(reader, reader.uint32()));
8214
+ continue;
8215
+ }
8216
+ case 4: {
8217
+ if (tag !== 34) {
8218
+ break;
8219
+ }
8220
+ message.conditionCombinations.push(ConditionCombination.decode(reader, reader.uint32()));
8221
+ continue;
8222
+ }
8223
+ case 5: {
8224
+ if (tag !== 42) {
8225
+ break;
8226
+ }
8227
+ message.subFlowConditions.push(SubFlowConditionState.decode(reader, reader.uint32()));
7710
8228
  continue;
7711
8229
  }
7712
8230
  }
@@ -7718,15 +8236,367 @@ export const TimerCondition = {
7718
8236
  return message;
7719
8237
  },
7720
8238
  create(base) {
7721
- return TimerCondition.fromPartial(base ?? {});
8239
+ return WaitingConditionState.fromPartial(base ?? {});
7722
8240
  },
7723
8241
  fromPartial(object) {
7724
- const message = createBaseTimerCondition();
7725
- message.conditionId = object.conditionId ?? "";
7726
- message.durationSeconds = (object.durationSeconds !== undefined && object.durationSeconds !== null)
7727
- ? BigInt(object.durationSeconds)
7728
- : 0n;
7729
- message.firingUnixTimestampSeconds =
8242
+ const message = createBaseWaitingConditionState();
8243
+ message.waitingConditionType = object.waitingConditionType ?? 0;
8244
+ message.timerConditions = object.timerConditions?.map((e) => TimerCondition.fromPartial(e)) || [];
8245
+ message.channelConditions = object.channelConditions?.map((e) => ChannelCondition.fromPartial(e)) || [];
8246
+ message.conditionCombinations = object.conditionCombinations?.map((e) => ConditionCombination.fromPartial(e)) || [];
8247
+ message.subFlowConditions = object.subFlowConditions?.map((e) => SubFlowConditionState.fromPartial(e)) || [];
8248
+ return message;
8249
+ },
8250
+ };
8251
+ function createBaseSubFlowOptions() {
8252
+ return {
8253
+ reusePolicy: 0,
8254
+ flowTimeoutSeconds: 0,
8255
+ flowStartDelaySeconds: 0,
8256
+ retryPolicy: undefined,
8257
+ attributes: [],
8258
+ flowConfigOverride: undefined,
8259
+ flowTimeoutPolicy: 0,
8260
+ };
8261
+ }
8262
+ export const SubFlowOptions = {
8263
+ encode(message, writer = new BinaryWriter()) {
8264
+ if (message.reusePolicy !== 0) {
8265
+ writer.uint32(8).int32(message.reusePolicy);
8266
+ }
8267
+ if (message.flowTimeoutSeconds !== 0) {
8268
+ writer.uint32(16).int32(message.flowTimeoutSeconds);
8269
+ }
8270
+ if (message.flowStartDelaySeconds !== 0) {
8271
+ writer.uint32(24).int32(message.flowStartDelaySeconds);
8272
+ }
8273
+ if (message.retryPolicy !== undefined) {
8274
+ FlowRetryPolicy.encode(message.retryPolicy, writer.uint32(34).fork()).join();
8275
+ }
8276
+ for (const v of message.attributes) {
8277
+ AttributeWrite.encode(v, writer.uint32(42).fork()).join();
8278
+ }
8279
+ if (message.flowConfigOverride !== undefined) {
8280
+ FlowConfig.encode(message.flowConfigOverride, writer.uint32(50).fork()).join();
8281
+ }
8282
+ if (message.flowTimeoutPolicy !== 0) {
8283
+ writer.uint32(56).int32(message.flowTimeoutPolicy);
8284
+ }
8285
+ return writer;
8286
+ },
8287
+ decode(input, length) {
8288
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
8289
+ const end = length === undefined ? reader.len : reader.pos + length;
8290
+ const message = createBaseSubFlowOptions();
8291
+ while (reader.pos < end) {
8292
+ const tag = reader.uint32();
8293
+ switch (tag >>> 3) {
8294
+ case 1: {
8295
+ if (tag !== 8) {
8296
+ break;
8297
+ }
8298
+ message.reusePolicy = reader.int32();
8299
+ continue;
8300
+ }
8301
+ case 2: {
8302
+ if (tag !== 16) {
8303
+ break;
8304
+ }
8305
+ message.flowTimeoutSeconds = reader.int32();
8306
+ continue;
8307
+ }
8308
+ case 3: {
8309
+ if (tag !== 24) {
8310
+ break;
8311
+ }
8312
+ message.flowStartDelaySeconds = reader.int32();
8313
+ continue;
8314
+ }
8315
+ case 4: {
8316
+ if (tag !== 34) {
8317
+ break;
8318
+ }
8319
+ message.retryPolicy = FlowRetryPolicy.decode(reader, reader.uint32());
8320
+ continue;
8321
+ }
8322
+ case 5: {
8323
+ if (tag !== 42) {
8324
+ break;
8325
+ }
8326
+ message.attributes.push(AttributeWrite.decode(reader, reader.uint32()));
8327
+ continue;
8328
+ }
8329
+ case 6: {
8330
+ if (tag !== 50) {
8331
+ break;
8332
+ }
8333
+ message.flowConfigOverride = FlowConfig.decode(reader, reader.uint32());
8334
+ continue;
8335
+ }
8336
+ case 7: {
8337
+ if (tag !== 56) {
8338
+ break;
8339
+ }
8340
+ message.flowTimeoutPolicy = reader.int32();
8341
+ continue;
8342
+ }
8343
+ }
8344
+ if ((tag & 7) === 4 || tag === 0) {
8345
+ break;
8346
+ }
8347
+ reader.skip(tag & 7);
8348
+ }
8349
+ return message;
8350
+ },
8351
+ create(base) {
8352
+ return SubFlowOptions.fromPartial(base ?? {});
8353
+ },
8354
+ fromPartial(object) {
8355
+ const message = createBaseSubFlowOptions();
8356
+ message.reusePolicy = object.reusePolicy ?? 0;
8357
+ message.flowTimeoutSeconds = object.flowTimeoutSeconds ?? 0;
8358
+ message.flowStartDelaySeconds = object.flowStartDelaySeconds ?? 0;
8359
+ message.retryPolicy = (object.retryPolicy !== undefined && object.retryPolicy !== null)
8360
+ ? FlowRetryPolicy.fromPartial(object.retryPolicy)
8361
+ : undefined;
8362
+ message.attributes = object.attributes?.map((e) => AttributeWrite.fromPartial(e)) || [];
8363
+ message.flowConfigOverride = (object.flowConfigOverride !== undefined && object.flowConfigOverride !== null)
8364
+ ? FlowConfig.fromPartial(object.flowConfigOverride)
8365
+ : undefined;
8366
+ message.flowTimeoutPolicy = object.flowTimeoutPolicy ?? 0;
8367
+ return message;
8368
+ },
8369
+ };
8370
+ function createBaseSubFlowCondition() {
8371
+ return {
8372
+ conditionId: "",
8373
+ subFlowType: "",
8374
+ startStepType: "",
8375
+ stepInput: undefined,
8376
+ stepOptions: undefined,
8377
+ options: undefined,
8378
+ subFlowIndex: 0,
8379
+ };
8380
+ }
8381
+ export const SubFlowCondition = {
8382
+ encode(message, writer = new BinaryWriter()) {
8383
+ if (message.conditionId !== "") {
8384
+ writer.uint32(10).string(message.conditionId);
8385
+ }
8386
+ if (message.subFlowType !== "") {
8387
+ writer.uint32(18).string(message.subFlowType);
8388
+ }
8389
+ if (message.startStepType !== "") {
8390
+ writer.uint32(26).string(message.startStepType);
8391
+ }
8392
+ if (message.stepInput !== undefined) {
8393
+ Value.encode(message.stepInput, writer.uint32(34).fork()).join();
8394
+ }
8395
+ if (message.stepOptions !== undefined) {
8396
+ StepOptions.encode(message.stepOptions, writer.uint32(42).fork()).join();
8397
+ }
8398
+ if (message.options !== undefined) {
8399
+ SubFlowOptions.encode(message.options, writer.uint32(50).fork()).join();
8400
+ }
8401
+ if (message.subFlowIndex !== 0) {
8402
+ writer.uint32(56).int32(message.subFlowIndex);
8403
+ }
8404
+ return writer;
8405
+ },
8406
+ decode(input, length) {
8407
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
8408
+ const end = length === undefined ? reader.len : reader.pos + length;
8409
+ const message = createBaseSubFlowCondition();
8410
+ while (reader.pos < end) {
8411
+ const tag = reader.uint32();
8412
+ switch (tag >>> 3) {
8413
+ case 1: {
8414
+ if (tag !== 10) {
8415
+ break;
8416
+ }
8417
+ message.conditionId = reader.string();
8418
+ continue;
8419
+ }
8420
+ case 2: {
8421
+ if (tag !== 18) {
8422
+ break;
8423
+ }
8424
+ message.subFlowType = reader.string();
8425
+ continue;
8426
+ }
8427
+ case 3: {
8428
+ if (tag !== 26) {
8429
+ break;
8430
+ }
8431
+ message.startStepType = reader.string();
8432
+ continue;
8433
+ }
8434
+ case 4: {
8435
+ if (tag !== 34) {
8436
+ break;
8437
+ }
8438
+ message.stepInput = Value.decode(reader, reader.uint32());
8439
+ continue;
8440
+ }
8441
+ case 5: {
8442
+ if (tag !== 42) {
8443
+ break;
8444
+ }
8445
+ message.stepOptions = StepOptions.decode(reader, reader.uint32());
8446
+ continue;
8447
+ }
8448
+ case 6: {
8449
+ if (tag !== 50) {
8450
+ break;
8451
+ }
8452
+ message.options = SubFlowOptions.decode(reader, reader.uint32());
8453
+ continue;
8454
+ }
8455
+ case 7: {
8456
+ if (tag !== 56) {
8457
+ break;
8458
+ }
8459
+ message.subFlowIndex = reader.int32();
8460
+ continue;
8461
+ }
8462
+ }
8463
+ if ((tag & 7) === 4 || tag === 0) {
8464
+ break;
8465
+ }
8466
+ reader.skip(tag & 7);
8467
+ }
8468
+ return message;
8469
+ },
8470
+ create(base) {
8471
+ return SubFlowCondition.fromPartial(base ?? {});
8472
+ },
8473
+ fromPartial(object) {
8474
+ const message = createBaseSubFlowCondition();
8475
+ message.conditionId = object.conditionId ?? "";
8476
+ message.subFlowType = object.subFlowType ?? "";
8477
+ message.startStepType = object.startStepType ?? "";
8478
+ message.stepInput = (object.stepInput !== undefined && object.stepInput !== null)
8479
+ ? Value.fromPartial(object.stepInput)
8480
+ : undefined;
8481
+ message.stepOptions = (object.stepOptions !== undefined && object.stepOptions !== null)
8482
+ ? StepOptions.fromPartial(object.stepOptions)
8483
+ : undefined;
8484
+ message.options = (object.options !== undefined && object.options !== null)
8485
+ ? SubFlowOptions.fromPartial(object.options)
8486
+ : undefined;
8487
+ message.subFlowIndex = object.subFlowIndex ?? 0;
8488
+ return message;
8489
+ },
8490
+ };
8491
+ function createBaseSubFlowConditionState() {
8492
+ return { conditionId: "" };
8493
+ }
8494
+ export const SubFlowConditionState = {
8495
+ encode(message, writer = new BinaryWriter()) {
8496
+ if (message.conditionId !== "") {
8497
+ writer.uint32(10).string(message.conditionId);
8498
+ }
8499
+ return writer;
8500
+ },
8501
+ decode(input, length) {
8502
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
8503
+ const end = length === undefined ? reader.len : reader.pos + length;
8504
+ const message = createBaseSubFlowConditionState();
8505
+ while (reader.pos < end) {
8506
+ const tag = reader.uint32();
8507
+ switch (tag >>> 3) {
8508
+ case 1: {
8509
+ if (tag !== 10) {
8510
+ break;
8511
+ }
8512
+ message.conditionId = reader.string();
8513
+ continue;
8514
+ }
8515
+ }
8516
+ if ((tag & 7) === 4 || tag === 0) {
8517
+ break;
8518
+ }
8519
+ reader.skip(tag & 7);
8520
+ }
8521
+ return message;
8522
+ },
8523
+ create(base) {
8524
+ return SubFlowConditionState.fromPartial(base ?? {});
8525
+ },
8526
+ fromPartial(object) {
8527
+ const message = createBaseSubFlowConditionState();
8528
+ message.conditionId = object.conditionId ?? "";
8529
+ return message;
8530
+ },
8531
+ };
8532
+ function createBaseTimerCondition() {
8533
+ return { conditionId: "", durationSeconds: 0n, firingUnixTimestampSeconds: 0n };
8534
+ }
8535
+ export const TimerCondition = {
8536
+ encode(message, writer = new BinaryWriter()) {
8537
+ if (message.conditionId !== "") {
8538
+ writer.uint32(10).string(message.conditionId);
8539
+ }
8540
+ if (message.durationSeconds !== 0n) {
8541
+ if (BigInt.asIntN(64, message.durationSeconds) !== message.durationSeconds) {
8542
+ throw new globalThis.Error("value provided for field message.durationSeconds of type int64 too large");
8543
+ }
8544
+ writer.uint32(16).int64(message.durationSeconds);
8545
+ }
8546
+ if (message.firingUnixTimestampSeconds !== 0n) {
8547
+ if (BigInt.asIntN(64, message.firingUnixTimestampSeconds) !== message.firingUnixTimestampSeconds) {
8548
+ throw new globalThis.Error("value provided for field message.firingUnixTimestampSeconds of type int64 too large");
8549
+ }
8550
+ writer.uint32(24).int64(message.firingUnixTimestampSeconds);
8551
+ }
8552
+ return writer;
8553
+ },
8554
+ decode(input, length) {
8555
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
8556
+ const end = length === undefined ? reader.len : reader.pos + length;
8557
+ const message = createBaseTimerCondition();
8558
+ while (reader.pos < end) {
8559
+ const tag = reader.uint32();
8560
+ switch (tag >>> 3) {
8561
+ case 1: {
8562
+ if (tag !== 10) {
8563
+ break;
8564
+ }
8565
+ message.conditionId = reader.string();
8566
+ continue;
8567
+ }
8568
+ case 2: {
8569
+ if (tag !== 16) {
8570
+ break;
8571
+ }
8572
+ message.durationSeconds = reader.int64();
8573
+ continue;
8574
+ }
8575
+ case 3: {
8576
+ if (tag !== 24) {
8577
+ break;
8578
+ }
8579
+ message.firingUnixTimestampSeconds = reader.int64();
8580
+ continue;
8581
+ }
8582
+ }
8583
+ if ((tag & 7) === 4 || tag === 0) {
8584
+ break;
8585
+ }
8586
+ reader.skip(tag & 7);
8587
+ }
8588
+ return message;
8589
+ },
8590
+ create(base) {
8591
+ return TimerCondition.fromPartial(base ?? {});
8592
+ },
8593
+ fromPartial(object) {
8594
+ const message = createBaseTimerCondition();
8595
+ message.conditionId = object.conditionId ?? "";
8596
+ message.durationSeconds = (object.durationSeconds !== undefined && object.durationSeconds !== null)
8597
+ ? BigInt(object.durationSeconds)
8598
+ : 0n;
8599
+ message.firingUnixTimestampSeconds =
7730
8600
  (object.firingUnixTimestampSeconds !== undefined && object.firingUnixTimestampSeconds !== null)
7731
8601
  ? BigInt(object.firingUnixTimestampSeconds)
7732
8602
  : 0n;
@@ -7808,7 +8678,7 @@ export const ChannelCondition = {
7808
8678
  },
7809
8679
  };
7810
8680
  function createBaseConditionResults() {
7811
- return { channelResults: [], timerResults: [], waitForFailed: false };
8681
+ return { channelResults: [], timerResults: [], waitForFailed: false, subFlowResults: [] };
7812
8682
  }
7813
8683
  export const ConditionResults = {
7814
8684
  encode(message, writer = new BinaryWriter()) {
@@ -7821,6 +8691,9 @@ export const ConditionResults = {
7821
8691
  if (message.waitForFailed !== false) {
7822
8692
  writer.uint32(24).bool(message.waitForFailed);
7823
8693
  }
8694
+ for (const v of message.subFlowResults) {
8695
+ FlowResult.encode(v, writer.uint32(34).fork()).join();
8696
+ }
7824
8697
  return writer;
7825
8698
  },
7826
8699
  decode(input, length) {
@@ -7851,6 +8724,13 @@ export const ConditionResults = {
7851
8724
  message.waitForFailed = reader.bool();
7852
8725
  continue;
7853
8726
  }
8727
+ case 4: {
8728
+ if (tag !== 34) {
8729
+ break;
8730
+ }
8731
+ message.subFlowResults.push(FlowResult.decode(reader, reader.uint32()));
8732
+ continue;
8733
+ }
7854
8734
  }
7855
8735
  if ((tag & 7) === 4 || tag === 0) {
7856
8736
  break;
@@ -7867,6 +8747,7 @@ export const ConditionResults = {
7867
8747
  message.channelResults = object.channelResults?.map((e) => ChannelResult.fromPartial(e)) || [];
7868
8748
  message.timerResults = object.timerResults?.map((e) => TimerResult.fromPartial(e)) || [];
7869
8749
  message.waitForFailed = object.waitForFailed ?? false;
8750
+ message.subFlowResults = object.subFlowResults?.map((e) => FlowResult.fromPartial(e)) || [];
7870
8751
  return message;
7871
8752
  },
7872
8753
  };
@@ -8186,13 +9067,16 @@ export const ChannelValues = {
8186
9067
  },
8187
9068
  };
8188
9069
  function createBaseStepExecutionCompletedConditions() {
8189
- return { completedTimerConditions: {} };
9070
+ return { completedTimerConditions: {}, completedSubFlowResults: {} };
8190
9071
  }
8191
9072
  export const StepExecutionCompletedConditions = {
8192
9073
  encode(message, writer = new BinaryWriter()) {
8193
9074
  globalThis.Object.entries(message.completedTimerConditions).forEach(([key, value]) => {
8194
9075
  StepExecutionCompletedConditions_CompletedTimerConditionsEntry.encode({ key: key, value }, writer.uint32(10).fork()).join();
8195
9076
  });
9077
+ globalThis.Object.entries(message.completedSubFlowResults).forEach(([key, value]) => {
9078
+ StepExecutionCompletedConditions_CompletedSubFlowResultsEntry.encode({ key: key, value }, writer.uint32(18).fork()).join();
9079
+ });
8196
9080
  return writer;
8197
9081
  },
8198
9082
  decode(input, length) {
@@ -8212,6 +9096,16 @@ export const StepExecutionCompletedConditions = {
8212
9096
  }
8213
9097
  continue;
8214
9098
  }
9099
+ case 2: {
9100
+ if (tag !== 18) {
9101
+ break;
9102
+ }
9103
+ const entry2 = StepExecutionCompletedConditions_CompletedSubFlowResultsEntry.decode(reader, reader.uint32());
9104
+ if (entry2.value !== undefined) {
9105
+ message.completedSubFlowResults[entry2.key] = entry2.value;
9106
+ }
9107
+ continue;
9108
+ }
8215
9109
  }
8216
9110
  if ((tag & 7) === 4 || tag === 0) {
8217
9111
  break;
@@ -8232,6 +9126,13 @@ export const StepExecutionCompletedConditions = {
8232
9126
  }
8233
9127
  return acc;
8234
9128
  }, {});
9129
+ message.completedSubFlowResults =
9130
+ globalThis.Object.entries(object.completedSubFlowResults ?? {}).reduce((acc, [key, value]) => {
9131
+ if (value !== undefined) {
9132
+ acc[globalThis.Number(key)] = FlowResult.fromPartial(value);
9133
+ }
9134
+ return acc;
9135
+ }, {});
8235
9136
  return message;
8236
9137
  },
8237
9138
  };
@@ -8287,6 +9188,60 @@ export const StepExecutionCompletedConditions_CompletedTimerConditionsEntry = {
8287
9188
  return message;
8288
9189
  },
8289
9190
  };
9191
+ function createBaseStepExecutionCompletedConditions_CompletedSubFlowResultsEntry() {
9192
+ return { key: 0, value: undefined };
9193
+ }
9194
+ export const StepExecutionCompletedConditions_CompletedSubFlowResultsEntry = {
9195
+ encode(message, writer = new BinaryWriter()) {
9196
+ if (message.key !== 0) {
9197
+ writer.uint32(8).int32(message.key);
9198
+ }
9199
+ if (message.value !== undefined) {
9200
+ FlowResult.encode(message.value, writer.uint32(18).fork()).join();
9201
+ }
9202
+ return writer;
9203
+ },
9204
+ decode(input, length) {
9205
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
9206
+ const end = length === undefined ? reader.len : reader.pos + length;
9207
+ const message = createBaseStepExecutionCompletedConditions_CompletedSubFlowResultsEntry();
9208
+ while (reader.pos < end) {
9209
+ const tag = reader.uint32();
9210
+ switch (tag >>> 3) {
9211
+ case 1: {
9212
+ if (tag !== 8) {
9213
+ break;
9214
+ }
9215
+ message.key = reader.int32();
9216
+ continue;
9217
+ }
9218
+ case 2: {
9219
+ if (tag !== 18) {
9220
+ break;
9221
+ }
9222
+ message.value = FlowResult.decode(reader, reader.uint32());
9223
+ continue;
9224
+ }
9225
+ }
9226
+ if ((tag & 7) === 4 || tag === 0) {
9227
+ break;
9228
+ }
9229
+ reader.skip(tag & 7);
9230
+ }
9231
+ return message;
9232
+ },
9233
+ create(base) {
9234
+ return StepExecutionCompletedConditions_CompletedSubFlowResultsEntry.fromPartial(base ?? {});
9235
+ },
9236
+ fromPartial(object) {
9237
+ const message = createBaseStepExecutionCompletedConditions_CompletedSubFlowResultsEntry();
9238
+ message.key = object.key ?? 0;
9239
+ message.value = (object.value !== undefined && object.value !== null)
9240
+ ? FlowResult.fromPartial(object.value)
9241
+ : undefined;
9242
+ return message;
9243
+ },
9244
+ };
8290
9245
  function createBaseStepExecutionResumeInfo() {
8291
9246
  return {
8292
9247
  stepExecutionId: "",
@@ -8308,7 +9263,7 @@ export const StepExecutionResumeInfo = {
8308
9263
  StepExecutionCompletedConditions.encode(message.completedConditions, writer.uint32(26).fork()).join();
8309
9264
  }
8310
9265
  if (message.waitingCondition !== undefined) {
8311
- WaitingCondition.encode(message.waitingCondition, writer.uint32(34).fork()).join();
9266
+ WaitingConditionState.encode(message.waitingCondition, writer.uint32(34).fork()).join();
8312
9267
  }
8313
9268
  for (const v of message.stepExeLocals) {
8314
9269
  KV.encode(v, writer.uint32(42).fork()).join();
@@ -8347,7 +9302,7 @@ export const StepExecutionResumeInfo = {
8347
9302
  if (tag !== 34) {
8348
9303
  break;
8349
9304
  }
8350
- message.waitingCondition = WaitingCondition.decode(reader, reader.uint32());
9305
+ message.waitingCondition = WaitingConditionState.decode(reader, reader.uint32());
8351
9306
  continue;
8352
9307
  }
8353
9308
  case 5: {
@@ -8378,7 +9333,7 @@ export const StepExecutionResumeInfo = {
8378
9333
  ? StepExecutionCompletedConditions.fromPartial(object.completedConditions)
8379
9334
  : undefined;
8380
9335
  message.waitingCondition = (object.waitingCondition !== undefined && object.waitingCondition !== null)
8381
- ? WaitingCondition.fromPartial(object.waitingCondition)
9336
+ ? WaitingConditionState.fromPartial(object.waitingCondition)
8382
9337
  : undefined;
8383
9338
  message.stepExeLocals = object.stepExeLocals?.map((e) => KV.fromPartial(e)) || [];
8384
9339
  return message;
@@ -8950,6 +9905,8 @@ export const ContinueAsNewInput = {
8950
9905
  function createBaseInterpreterWorkflowInput() {
8951
9906
  return {
8952
9907
  flowType: "",
9908
+ configuredFlowTimeoutSeconds: 0,
9909
+ flowTimeoutPolicy: 0,
8953
9910
  startStepType: "",
8954
9911
  stepInput: undefined,
8955
9912
  stepOptions: undefined,
@@ -8964,26 +9921,32 @@ export const InterpreterWorkflowInput = {
8964
9921
  if (message.flowType !== "") {
8965
9922
  writer.uint32(10).string(message.flowType);
8966
9923
  }
9924
+ if (message.configuredFlowTimeoutSeconds !== 0) {
9925
+ writer.uint32(16).int32(message.configuredFlowTimeoutSeconds);
9926
+ }
9927
+ if (message.flowTimeoutPolicy !== 0) {
9928
+ writer.uint32(24).int32(message.flowTimeoutPolicy);
9929
+ }
8967
9930
  if (message.startStepType !== "") {
8968
- writer.uint32(26).string(message.startStepType);
9931
+ writer.uint32(34).string(message.startStepType);
8969
9932
  }
8970
9933
  if (message.stepInput !== undefined) {
8971
- Value.encode(message.stepInput, writer.uint32(50).fork()).join();
9934
+ Value.encode(message.stepInput, writer.uint32(42).fork()).join();
8972
9935
  }
8973
9936
  if (message.stepOptions !== undefined) {
8974
- StepOptions.encode(message.stepOptions, writer.uint32(58).fork()).join();
9937
+ StepOptions.encode(message.stepOptions, writer.uint32(50).fork()).join();
8975
9938
  }
8976
9939
  for (const v of message.initAttributes) {
8977
- AttributeWrite.encode(v, writer.uint32(66).fork()).join();
9940
+ AttributeWrite.encode(v, writer.uint32(58).fork()).join();
8978
9941
  }
8979
9942
  if (message.config !== undefined) {
8980
- FlowConfig.encode(message.config, writer.uint32(74).fork()).join();
9943
+ FlowConfig.encode(message.config, writer.uint32(66).fork()).join();
8981
9944
  }
8982
9945
  if (message.isResumeFromContinueAsNew !== false) {
8983
- writer.uint32(80).bool(message.isResumeFromContinueAsNew);
9946
+ writer.uint32(72).bool(message.isResumeFromContinueAsNew);
8984
9947
  }
8985
9948
  if (message.continueAsNewInput !== undefined) {
8986
- ContinueAsNewInput.encode(message.continueAsNewInput, writer.uint32(90).fork()).join();
9949
+ ContinueAsNewInput.encode(message.continueAsNewInput, writer.uint32(82).fork()).join();
8987
9950
  }
8988
9951
  return writer;
8989
9952
  },
@@ -9001,50 +9964,64 @@ export const InterpreterWorkflowInput = {
9001
9964
  message.flowType = reader.string();
9002
9965
  continue;
9003
9966
  }
9967
+ case 2: {
9968
+ if (tag !== 16) {
9969
+ break;
9970
+ }
9971
+ message.configuredFlowTimeoutSeconds = reader.int32();
9972
+ continue;
9973
+ }
9004
9974
  case 3: {
9005
- if (tag !== 26) {
9975
+ if (tag !== 24) {
9976
+ break;
9977
+ }
9978
+ message.flowTimeoutPolicy = reader.int32();
9979
+ continue;
9980
+ }
9981
+ case 4: {
9982
+ if (tag !== 34) {
9006
9983
  break;
9007
9984
  }
9008
9985
  message.startStepType = reader.string();
9009
9986
  continue;
9010
9987
  }
9011
- case 6: {
9012
- if (tag !== 50) {
9988
+ case 5: {
9989
+ if (tag !== 42) {
9013
9990
  break;
9014
9991
  }
9015
9992
  message.stepInput = Value.decode(reader, reader.uint32());
9016
9993
  continue;
9017
9994
  }
9018
- case 7: {
9019
- if (tag !== 58) {
9995
+ case 6: {
9996
+ if (tag !== 50) {
9020
9997
  break;
9021
9998
  }
9022
9999
  message.stepOptions = StepOptions.decode(reader, reader.uint32());
9023
10000
  continue;
9024
10001
  }
9025
- case 8: {
9026
- if (tag !== 66) {
10002
+ case 7: {
10003
+ if (tag !== 58) {
9027
10004
  break;
9028
10005
  }
9029
10006
  message.initAttributes.push(AttributeWrite.decode(reader, reader.uint32()));
9030
10007
  continue;
9031
10008
  }
9032
- case 9: {
9033
- if (tag !== 74) {
10009
+ case 8: {
10010
+ if (tag !== 66) {
9034
10011
  break;
9035
10012
  }
9036
10013
  message.config = FlowConfig.decode(reader, reader.uint32());
9037
10014
  continue;
9038
10015
  }
9039
- case 10: {
9040
- if (tag !== 80) {
10016
+ case 9: {
10017
+ if (tag !== 72) {
9041
10018
  break;
9042
10019
  }
9043
10020
  message.isResumeFromContinueAsNew = reader.bool();
9044
10021
  continue;
9045
10022
  }
9046
- case 11: {
9047
- if (tag !== 90) {
10023
+ case 10: {
10024
+ if (tag !== 82) {
9048
10025
  break;
9049
10026
  }
9050
10027
  message.continueAsNewInput = ContinueAsNewInput.decode(reader, reader.uint32());
@@ -9064,6 +10041,8 @@ export const InterpreterWorkflowInput = {
9064
10041
  fromPartial(object) {
9065
10042
  const message = createBaseInterpreterWorkflowInput();
9066
10043
  message.flowType = object.flowType ?? "";
10044
+ message.configuredFlowTimeoutSeconds = object.configuredFlowTimeoutSeconds ?? 0;
10045
+ message.flowTimeoutPolicy = object.flowTimeoutPolicy ?? 0;
9067
10046
  message.startStepType = object.startStepType ?? "";
9068
10047
  message.stepInput = (object.stepInput !== undefined && object.stepInput !== null)
9069
10048
  ? Value.fromPartial(object.stepInput)
@@ -9305,25 +10284,148 @@ export const InvokeWaitForMethodActivityOutput = {
9305
10284
  },
9306
10285
  };
9307
10286
  function createBaseInvokeExecuteMethodActivityInput() {
9308
- return { workerTarget: undefined, request: undefined, isTransientStep: false };
10287
+ return { workerTarget: undefined, request: undefined };
9309
10288
  }
9310
10289
  export const InvokeExecuteMethodActivityInput = {
9311
10290
  encode(message, writer = new BinaryWriter()) {
9312
10291
  if (message.workerTarget !== undefined) {
9313
10292
  WorkerTarget.encode(message.workerTarget, writer.uint32(10).fork()).join();
9314
10293
  }
9315
- if (message.request !== undefined) {
9316
- InvokeExecuteMethodRequest.encode(message.request, writer.uint32(18).fork()).join();
10294
+ if (message.request !== undefined) {
10295
+ InvokeExecuteMethodRequest.encode(message.request, writer.uint32(18).fork()).join();
10296
+ }
10297
+ return writer;
10298
+ },
10299
+ decode(input, length) {
10300
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
10301
+ const end = length === undefined ? reader.len : reader.pos + length;
10302
+ const message = createBaseInvokeExecuteMethodActivityInput();
10303
+ while (reader.pos < end) {
10304
+ const tag = reader.uint32();
10305
+ switch (tag >>> 3) {
10306
+ case 1: {
10307
+ if (tag !== 10) {
10308
+ break;
10309
+ }
10310
+ message.workerTarget = WorkerTarget.decode(reader, reader.uint32());
10311
+ continue;
10312
+ }
10313
+ case 2: {
10314
+ if (tag !== 18) {
10315
+ break;
10316
+ }
10317
+ message.request = InvokeExecuteMethodRequest.decode(reader, reader.uint32());
10318
+ continue;
10319
+ }
10320
+ }
10321
+ if ((tag & 7) === 4 || tag === 0) {
10322
+ break;
10323
+ }
10324
+ reader.skip(tag & 7);
10325
+ }
10326
+ return message;
10327
+ },
10328
+ create(base) {
10329
+ return InvokeExecuteMethodActivityInput.fromPartial(base ?? {});
10330
+ },
10331
+ fromPartial(object) {
10332
+ const message = createBaseInvokeExecuteMethodActivityInput();
10333
+ message.workerTarget = (object.workerTarget !== undefined && object.workerTarget !== null)
10334
+ ? WorkerTarget.fromPartial(object.workerTarget)
10335
+ : undefined;
10336
+ message.request = (object.request !== undefined && object.request !== null)
10337
+ ? InvokeExecuteMethodRequest.fromPartial(object.request)
10338
+ : undefined;
10339
+ return message;
10340
+ },
10341
+ };
10342
+ function createBaseRecoveryErrorInfo() {
10343
+ return { detail: "", errorType: "" };
10344
+ }
10345
+ export const RecoveryErrorInfo = {
10346
+ encode(message, writer = new BinaryWriter()) {
10347
+ if (message.detail !== "") {
10348
+ writer.uint32(10).string(message.detail);
10349
+ }
10350
+ if (message.errorType !== "") {
10351
+ writer.uint32(18).string(message.errorType);
10352
+ }
10353
+ return writer;
10354
+ },
10355
+ decode(input, length) {
10356
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
10357
+ const end = length === undefined ? reader.len : reader.pos + length;
10358
+ const message = createBaseRecoveryErrorInfo();
10359
+ while (reader.pos < end) {
10360
+ const tag = reader.uint32();
10361
+ switch (tag >>> 3) {
10362
+ case 1: {
10363
+ if (tag !== 10) {
10364
+ break;
10365
+ }
10366
+ message.detail = reader.string();
10367
+ continue;
10368
+ }
10369
+ case 2: {
10370
+ if (tag !== 18) {
10371
+ break;
10372
+ }
10373
+ message.errorType = reader.string();
10374
+ continue;
10375
+ }
10376
+ }
10377
+ if ((tag & 7) === 4 || tag === 0) {
10378
+ break;
10379
+ }
10380
+ reader.skip(tag & 7);
10381
+ }
10382
+ return message;
10383
+ },
10384
+ create(base) {
10385
+ return RecoveryErrorInfo.fromPartial(base ?? {});
10386
+ },
10387
+ fromPartial(object) {
10388
+ const message = createBaseRecoveryErrorInfo();
10389
+ message.detail = object.detail ?? "";
10390
+ message.errorType = object.errorType ?? "";
10391
+ return message;
10392
+ },
10393
+ };
10394
+ function createBaseInternalLocalStepActivityFailure() {
10395
+ return {
10396
+ localActivityMetadata: undefined,
10397
+ firstAttemptTimestamp: 0n,
10398
+ methodOptions: undefined,
10399
+ attempt: 0,
10400
+ activityError: undefined,
10401
+ };
10402
+ }
10403
+ export const InternalLocalStepActivityFailure = {
10404
+ encode(message, writer = new BinaryWriter()) {
10405
+ if (message.localActivityMetadata !== undefined) {
10406
+ LocalActivityMetadata.encode(message.localActivityMetadata, writer.uint32(10).fork()).join();
10407
+ }
10408
+ if (message.firstAttemptTimestamp !== 0n) {
10409
+ if (BigInt.asIntN(64, message.firstAttemptTimestamp) !== message.firstAttemptTimestamp) {
10410
+ throw new globalThis.Error("value provided for field message.firstAttemptTimestamp of type int64 too large");
10411
+ }
10412
+ writer.uint32(16).int64(message.firstAttemptTimestamp);
10413
+ }
10414
+ if (message.methodOptions !== undefined) {
10415
+ StepMethodOptions.encode(message.methodOptions, writer.uint32(26).fork()).join();
10416
+ }
10417
+ if (message.attempt !== 0) {
10418
+ writer.uint32(32).int32(message.attempt);
9317
10419
  }
9318
- if (message.isTransientStep !== false) {
9319
- writer.uint32(24).bool(message.isTransientStep);
10420
+ if (message.activityError !== undefined) {
10421
+ InternalActivityError.encode(message.activityError, writer.uint32(42).fork()).join();
9320
10422
  }
9321
10423
  return writer;
9322
10424
  },
9323
10425
  decode(input, length) {
9324
10426
  const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
9325
10427
  const end = length === undefined ? reader.len : reader.pos + length;
9326
- const message = createBaseInvokeExecuteMethodActivityInput();
10428
+ const message = createBaseInternalLocalStepActivityFailure();
9327
10429
  while (reader.pos < end) {
9328
10430
  const tag = reader.uint32();
9329
10431
  switch (tag >>> 3) {
@@ -9331,21 +10433,35 @@ export const InvokeExecuteMethodActivityInput = {
9331
10433
  if (tag !== 10) {
9332
10434
  break;
9333
10435
  }
9334
- message.workerTarget = WorkerTarget.decode(reader, reader.uint32());
10436
+ message.localActivityMetadata = LocalActivityMetadata.decode(reader, reader.uint32());
9335
10437
  continue;
9336
10438
  }
9337
10439
  case 2: {
9338
- if (tag !== 18) {
10440
+ if (tag !== 16) {
9339
10441
  break;
9340
10442
  }
9341
- message.request = InvokeExecuteMethodRequest.decode(reader, reader.uint32());
10443
+ message.firstAttemptTimestamp = reader.int64();
9342
10444
  continue;
9343
10445
  }
9344
10446
  case 3: {
9345
- if (tag !== 24) {
10447
+ if (tag !== 26) {
10448
+ break;
10449
+ }
10450
+ message.methodOptions = StepMethodOptions.decode(reader, reader.uint32());
10451
+ continue;
10452
+ }
10453
+ case 4: {
10454
+ if (tag !== 32) {
10455
+ break;
10456
+ }
10457
+ message.attempt = reader.int32();
10458
+ continue;
10459
+ }
10460
+ case 5: {
10461
+ if (tag !== 42) {
9346
10462
  break;
9347
10463
  }
9348
- message.isTransientStep = reader.bool();
10464
+ message.activityError = InternalActivityError.decode(reader, reader.uint32());
9349
10465
  continue;
9350
10466
  }
9351
10467
  }
@@ -9357,17 +10473,25 @@ export const InvokeExecuteMethodActivityInput = {
9357
10473
  return message;
9358
10474
  },
9359
10475
  create(base) {
9360
- return InvokeExecuteMethodActivityInput.fromPartial(base ?? {});
10476
+ return InternalLocalStepActivityFailure.fromPartial(base ?? {});
9361
10477
  },
9362
10478
  fromPartial(object) {
9363
- const message = createBaseInvokeExecuteMethodActivityInput();
9364
- message.workerTarget = (object.workerTarget !== undefined && object.workerTarget !== null)
9365
- ? WorkerTarget.fromPartial(object.workerTarget)
10479
+ const message = createBaseInternalLocalStepActivityFailure();
10480
+ message.localActivityMetadata =
10481
+ (object.localActivityMetadata !== undefined && object.localActivityMetadata !== null)
10482
+ ? LocalActivityMetadata.fromPartial(object.localActivityMetadata)
10483
+ : undefined;
10484
+ message.firstAttemptTimestamp =
10485
+ (object.firstAttemptTimestamp !== undefined && object.firstAttemptTimestamp !== null)
10486
+ ? BigInt(object.firstAttemptTimestamp)
10487
+ : 0n;
10488
+ message.methodOptions = (object.methodOptions !== undefined && object.methodOptions !== null)
10489
+ ? StepMethodOptions.fromPartial(object.methodOptions)
9366
10490
  : undefined;
9367
- message.request = (object.request !== undefined && object.request !== null)
9368
- ? InvokeExecuteMethodRequest.fromPartial(object.request)
10491
+ message.attempt = object.attempt ?? 0;
10492
+ message.activityError = (object.activityError !== undefined && object.activityError !== null)
10493
+ ? InternalActivityError.fromPartial(object.activityError)
9369
10494
  : undefined;
9370
- message.isTransientStep = object.isTransientStep ?? false;
9371
10495
  return message;
9372
10496
  },
9373
10497
  };
@@ -9557,13 +10681,16 @@ export const InvokeWorkerRPCActivityInput = {
9557
10681
  },
9558
10682
  };
9559
10683
  function createBaseInvokeWorkerRPCActivityOutput() {
9560
- return { response: undefined };
10684
+ return { response: undefined, requestId: "" };
9561
10685
  }
9562
10686
  export const InvokeWorkerRPCActivityOutput = {
9563
10687
  encode(message, writer = new BinaryWriter()) {
9564
10688
  if (message.response !== undefined) {
9565
10689
  InvokeWorkerRPCResponse.encode(message.response, writer.uint32(10).fork()).join();
9566
10690
  }
10691
+ if (message.requestId !== "") {
10692
+ writer.uint32(18).string(message.requestId);
10693
+ }
9567
10694
  return writer;
9568
10695
  },
9569
10696
  decode(input, length) {
@@ -9580,6 +10707,13 @@ export const InvokeWorkerRPCActivityOutput = {
9580
10707
  message.response = InvokeWorkerRPCResponse.decode(reader, reader.uint32());
9581
10708
  continue;
9582
10709
  }
10710
+ case 2: {
10711
+ if (tag !== 18) {
10712
+ break;
10713
+ }
10714
+ message.requestId = reader.string();
10715
+ continue;
10716
+ }
9583
10717
  }
9584
10718
  if ((tag & 7) === 4 || tag === 0) {
9585
10719
  break;
@@ -9596,6 +10730,7 @@ export const InvokeWorkerRPCActivityOutput = {
9596
10730
  message.response = (object.response !== undefined && object.response !== null)
9597
10731
  ? InvokeWorkerRPCResponse.fromPartial(object.response)
9598
10732
  : undefined;
10733
+ message.requestId = object.requestId ?? "";
9599
10734
  return message;
9600
10735
  },
9601
10736
  };
@@ -9807,6 +10942,265 @@ export const SyncAttributeBatchActivityInput = {
9807
10942
  return message;
9808
10943
  },
9809
10944
  };
10945
+ function createBaseStartSubFlowActivityInput() {
10946
+ return { condition: undefined, parentFlowConfig: undefined, parentStepExecutionId: "" };
10947
+ }
10948
+ export const StartSubFlowActivityInput = {
10949
+ encode(message, writer = new BinaryWriter()) {
10950
+ if (message.condition !== undefined) {
10951
+ SubFlowCondition.encode(message.condition, writer.uint32(10).fork()).join();
10952
+ }
10953
+ if (message.parentFlowConfig !== undefined) {
10954
+ FlowConfig.encode(message.parentFlowConfig, writer.uint32(18).fork()).join();
10955
+ }
10956
+ if (message.parentStepExecutionId !== "") {
10957
+ writer.uint32(26).string(message.parentStepExecutionId);
10958
+ }
10959
+ return writer;
10960
+ },
10961
+ decode(input, length) {
10962
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
10963
+ const end = length === undefined ? reader.len : reader.pos + length;
10964
+ const message = createBaseStartSubFlowActivityInput();
10965
+ while (reader.pos < end) {
10966
+ const tag = reader.uint32();
10967
+ switch (tag >>> 3) {
10968
+ case 1: {
10969
+ if (tag !== 10) {
10970
+ break;
10971
+ }
10972
+ message.condition = SubFlowCondition.decode(reader, reader.uint32());
10973
+ continue;
10974
+ }
10975
+ case 2: {
10976
+ if (tag !== 18) {
10977
+ break;
10978
+ }
10979
+ message.parentFlowConfig = FlowConfig.decode(reader, reader.uint32());
10980
+ continue;
10981
+ }
10982
+ case 3: {
10983
+ if (tag !== 26) {
10984
+ break;
10985
+ }
10986
+ message.parentStepExecutionId = reader.string();
10987
+ continue;
10988
+ }
10989
+ }
10990
+ if ((tag & 7) === 4 || tag === 0) {
10991
+ break;
10992
+ }
10993
+ reader.skip(tag & 7);
10994
+ }
10995
+ return message;
10996
+ },
10997
+ create(base) {
10998
+ return StartSubFlowActivityInput.fromPartial(base ?? {});
10999
+ },
11000
+ fromPartial(object) {
11001
+ const message = createBaseStartSubFlowActivityInput();
11002
+ message.condition = (object.condition !== undefined && object.condition !== null)
11003
+ ? SubFlowCondition.fromPartial(object.condition)
11004
+ : undefined;
11005
+ message.parentFlowConfig = (object.parentFlowConfig !== undefined && object.parentFlowConfig !== null)
11006
+ ? FlowConfig.fromPartial(object.parentFlowConfig)
11007
+ : undefined;
11008
+ message.parentStepExecutionId = object.parentStepExecutionId ?? "";
11009
+ return message;
11010
+ },
11011
+ };
11012
+ function createBaseStartSubFlowActivityOutput() {
11013
+ return { immediateFlowResult: undefined };
11014
+ }
11015
+ export const StartSubFlowActivityOutput = {
11016
+ encode(message, writer = new BinaryWriter()) {
11017
+ if (message.immediateFlowResult !== undefined) {
11018
+ FlowResult.encode(message.immediateFlowResult, writer.uint32(10).fork()).join();
11019
+ }
11020
+ return writer;
11021
+ },
11022
+ decode(input, length) {
11023
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
11024
+ const end = length === undefined ? reader.len : reader.pos + length;
11025
+ const message = createBaseStartSubFlowActivityOutput();
11026
+ while (reader.pos < end) {
11027
+ const tag = reader.uint32();
11028
+ switch (tag >>> 3) {
11029
+ case 1: {
11030
+ if (tag !== 10) {
11031
+ break;
11032
+ }
11033
+ message.immediateFlowResult = FlowResult.decode(reader, reader.uint32());
11034
+ continue;
11035
+ }
11036
+ }
11037
+ if ((tag & 7) === 4 || tag === 0) {
11038
+ break;
11039
+ }
11040
+ reader.skip(tag & 7);
11041
+ }
11042
+ return message;
11043
+ },
11044
+ create(base) {
11045
+ return StartSubFlowActivityOutput.fromPartial(base ?? {});
11046
+ },
11047
+ fromPartial(object) {
11048
+ const message = createBaseStartSubFlowActivityOutput();
11049
+ message.immediateFlowResult = (object.immediateFlowResult !== undefined && object.immediateFlowResult !== null)
11050
+ ? FlowResult.fromPartial(object.immediateFlowResult)
11051
+ : undefined;
11052
+ return message;
11053
+ },
11054
+ };
11055
+ function createBaseSubFlowCompletionSignalRequest() {
11056
+ return { subFlowId: "", flowResult: undefined };
11057
+ }
11058
+ export const SubFlowCompletionSignalRequest = {
11059
+ encode(message, writer = new BinaryWriter()) {
11060
+ if (message.subFlowId !== "") {
11061
+ writer.uint32(10).string(message.subFlowId);
11062
+ }
11063
+ if (message.flowResult !== undefined) {
11064
+ FlowResult.encode(message.flowResult, writer.uint32(18).fork()).join();
11065
+ }
11066
+ return writer;
11067
+ },
11068
+ decode(input, length) {
11069
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
11070
+ const end = length === undefined ? reader.len : reader.pos + length;
11071
+ const message = createBaseSubFlowCompletionSignalRequest();
11072
+ while (reader.pos < end) {
11073
+ const tag = reader.uint32();
11074
+ switch (tag >>> 3) {
11075
+ case 1: {
11076
+ if (tag !== 10) {
11077
+ break;
11078
+ }
11079
+ message.subFlowId = reader.string();
11080
+ continue;
11081
+ }
11082
+ case 2: {
11083
+ if (tag !== 18) {
11084
+ break;
11085
+ }
11086
+ message.flowResult = FlowResult.decode(reader, reader.uint32());
11087
+ continue;
11088
+ }
11089
+ }
11090
+ if ((tag & 7) === 4 || tag === 0) {
11091
+ break;
11092
+ }
11093
+ reader.skip(tag & 7);
11094
+ }
11095
+ return message;
11096
+ },
11097
+ create(base) {
11098
+ return SubFlowCompletionSignalRequest.fromPartial(base ?? {});
11099
+ },
11100
+ fromPartial(object) {
11101
+ const message = createBaseSubFlowCompletionSignalRequest();
11102
+ message.subFlowId = object.subFlowId ?? "";
11103
+ message.flowResult = (object.flowResult !== undefined && object.flowResult !== null)
11104
+ ? FlowResult.fromPartial(object.flowResult)
11105
+ : undefined;
11106
+ return message;
11107
+ },
11108
+ };
11109
+ function createBaseReportSubFlowCompletionActivityInput() {
11110
+ return { parentFlowId: "", request: undefined };
11111
+ }
11112
+ export const ReportSubFlowCompletionActivityInput = {
11113
+ encode(message, writer = new BinaryWriter()) {
11114
+ if (message.parentFlowId !== "") {
11115
+ writer.uint32(10).string(message.parentFlowId);
11116
+ }
11117
+ if (message.request !== undefined) {
11118
+ SubFlowCompletionSignalRequest.encode(message.request, writer.uint32(18).fork()).join();
11119
+ }
11120
+ return writer;
11121
+ },
11122
+ decode(input, length) {
11123
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
11124
+ const end = length === undefined ? reader.len : reader.pos + length;
11125
+ const message = createBaseReportSubFlowCompletionActivityInput();
11126
+ while (reader.pos < end) {
11127
+ const tag = reader.uint32();
11128
+ switch (tag >>> 3) {
11129
+ case 1: {
11130
+ if (tag !== 10) {
11131
+ break;
11132
+ }
11133
+ message.parentFlowId = reader.string();
11134
+ continue;
11135
+ }
11136
+ case 2: {
11137
+ if (tag !== 18) {
11138
+ break;
11139
+ }
11140
+ message.request = SubFlowCompletionSignalRequest.decode(reader, reader.uint32());
11141
+ continue;
11142
+ }
11143
+ }
11144
+ if ((tag & 7) === 4 || tag === 0) {
11145
+ break;
11146
+ }
11147
+ reader.skip(tag & 7);
11148
+ }
11149
+ return message;
11150
+ },
11151
+ create(base) {
11152
+ return ReportSubFlowCompletionActivityInput.fromPartial(base ?? {});
11153
+ },
11154
+ fromPartial(object) {
11155
+ const message = createBaseReportSubFlowCompletionActivityInput();
11156
+ message.parentFlowId = object.parentFlowId ?? "";
11157
+ message.request = (object.request !== undefined && object.request !== null)
11158
+ ? SubFlowCompletionSignalRequest.fromPartial(object.request)
11159
+ : undefined;
11160
+ return message;
11161
+ },
11162
+ };
11163
+ function createBaseReportSubFlowCompletionActivityOutput() {
11164
+ return { status: 0 };
11165
+ }
11166
+ export const ReportSubFlowCompletionActivityOutput = {
11167
+ encode(message, writer = new BinaryWriter()) {
11168
+ if (message.status !== 0) {
11169
+ writer.uint32(8).int32(message.status);
11170
+ }
11171
+ return writer;
11172
+ },
11173
+ decode(input, length) {
11174
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
11175
+ const end = length === undefined ? reader.len : reader.pos + length;
11176
+ const message = createBaseReportSubFlowCompletionActivityOutput();
11177
+ while (reader.pos < end) {
11178
+ const tag = reader.uint32();
11179
+ switch (tag >>> 3) {
11180
+ case 1: {
11181
+ if (tag !== 8) {
11182
+ break;
11183
+ }
11184
+ message.status = reader.int32();
11185
+ continue;
11186
+ }
11187
+ }
11188
+ if ((tag & 7) === 4 || tag === 0) {
11189
+ break;
11190
+ }
11191
+ reader.skip(tag & 7);
11192
+ }
11193
+ return message;
11194
+ },
11195
+ create(base) {
11196
+ return ReportSubFlowCompletionActivityOutput.fromPartial(base ?? {});
11197
+ },
11198
+ fromPartial(object) {
11199
+ const message = createBaseReportSubFlowCompletionActivityOutput();
11200
+ message.status = object.status ?? 0;
11201
+ return message;
11202
+ },
11203
+ };
9810
11204
  function createBaseExecuteRpcSignalRequest() {
9811
11205
  return {
9812
11206
  rpcInput: undefined,
@@ -9815,6 +11209,7 @@ function createBaseExecuteRpcSignalRequest() {
9815
11209
  stepDecision: undefined,
9816
11210
  recordEvents: [],
9817
11211
  publishToChannel: [],
11212
+ isSetAttributeApi: false,
9818
11213
  };
9819
11214
  }
9820
11215
  export const ExecuteRpcSignalRequest = {
@@ -9837,6 +11232,9 @@ export const ExecuteRpcSignalRequest = {
9837
11232
  for (const v of message.publishToChannel) {
9838
11233
  ChannelMessage.encode(v, writer.uint32(50).fork()).join();
9839
11234
  }
11235
+ if (message.isSetAttributeApi !== false) {
11236
+ writer.uint32(56).bool(message.isSetAttributeApi);
11237
+ }
9840
11238
  return writer;
9841
11239
  },
9842
11240
  decode(input, length) {
@@ -9888,6 +11286,13 @@ export const ExecuteRpcSignalRequest = {
9888
11286
  message.publishToChannel.push(ChannelMessage.decode(reader, reader.uint32()));
9889
11287
  continue;
9890
11288
  }
11289
+ case 7: {
11290
+ if (tag !== 56) {
11291
+ break;
11292
+ }
11293
+ message.isSetAttributeApi = reader.bool();
11294
+ continue;
11295
+ }
9891
11296
  }
9892
11297
  if ((tag & 7) === 4 || tag === 0) {
9893
11298
  break;
@@ -9913,6 +11318,7 @@ export const ExecuteRpcSignalRequest = {
9913
11318
  : undefined;
9914
11319
  message.recordEvents = object.recordEvents?.map((e) => KV.fromPartial(e)) || [];
9915
11320
  message.publishToChannel = object.publishToChannel?.map((e) => ChannelMessage.fromPartial(e)) || [];
11321
+ message.isSetAttributeApi = object.isSetAttributeApi ?? false;
9916
11322
  return message;
9917
11323
  },
9918
11324
  };
@@ -10837,8 +12243,8 @@ export const FlowServiceService = {
10837
12243
  responseStream: false,
10838
12244
  requestSerialize: (value) => Buffer.from(WaitForFlowRequest.encode(value).finish()),
10839
12245
  requestDeserialize: (value) => WaitForFlowRequest.decode(value),
10840
- responseSerialize: (value) => Buffer.from(WaitForFlowResponse.encode(value).finish()),
10841
- responseDeserialize: (value) => WaitForFlowResponse.decode(value),
12246
+ responseSerialize: (value) => Buffer.from(FlowResult.encode(value).finish()),
12247
+ responseDeserialize: (value) => FlowResult.decode(value),
10842
12248
  },
10843
12249
  searchFlows: {
10844
12250
  path: "/dex.FlowService/SearchFlows",