Skip to content

Commit 45c407e

Browse files
committed
add explanation for fast-forward override
1 parent 3187a62 commit 45c407e

4 files changed

Lines changed: 22 additions & 6 deletions

File tree

openapi/openapiv2.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19680,14 +19680,14 @@
1968019680
},
1968119681
"fastForward": {
1968219682
"type": "string",
19683-
"description": "Optionally fast-forward the current workflow execution by this duration ahead of current workflow execution time.\nWhen the fast-forward completes, time skipping is disabled by the call that initiated the fast-forward, and this\naction is recorded in the WorkflowExecutionTimeSkippingTransitionedEvent. It can be re-enabled by\nsetting `enabled` to true via UpdateWorkflowExecutionOptions.\nThe current workflow execution is a chain of runs (retries, cron, continue-as-new);\nchild workflows are separate executions, so this fast_forward won't affect them."
19683+
"description": "Optionally fast-forward the current workflow execution by this duration ahead of current workflow execution time.\nWhen the fast-forward completes, time skipping is disabled by the call that initiated the fast-forward, and this\naction is recorded in the WorkflowExecutionTimeSkippingTransitionedEvent. It can be re-enabled by\nsetting `enabled` to true via UpdateWorkflowExecutionOptions.\nThe current workflow execution is a chain of runs (retries, cron, continue-as-new);\nchild workflows are separate executions, so this fast_forward won't affect them.\n\nFor a given workflow execution, only one active fast-forward is allowed at a time.\nIf a new fast-forward is set via UpdateWorkflowExecutionOptions before the previous\none completes, the new one will override the previous one.\nIf the fast-forward duration exceeds the remaining execution timeout, time will only\nbe fast-forwarded up to the end of the execution."
1968419684
},
1968519685
"disableChildPropagation": {
1968619686
"type": "boolean",
1968719687
"description": "By default, child workflows inherit the \"enabled\" flag when they are started.\nThis flag disables that inheritance."
1968819688
}
1968919689
},
19690-
"description": "The configuration for time skipping of a workflow execution (a chain of runs including retries, cron, continue-as-new).\nWhen time skipping is enabled, virtual time advances automatically whenever there is no in-flight work.\nIn-flight work includes activities, child workflows, Nexus operations, signal/cancel external workflow operations,\nand possibly other features added in the future.\nUser timers are not classified as in-flight work and will be skipped over; the virtual clock may also skip to the\ntime point of the registered fast_forward when there is no in-flight work.\n\nFor child workflows, by default, if the parent execution is skipping time, the child execution will also skip time,\nbut a parent's fast_forward won't affect its child's execution. A flag is provided to disable propagation of the\n\"enabled\" flag to child workflows; regardless of that flag, a child workflow inherits the virtual time from the\nparent execution as its start time."
19690+
"description": "The configuration for time skipping of a workflow execution (a chain of runs including retries, cron, continue-as-new).\nWhen time skipping is enabled, virtual time advances automatically whenever there is no in-flight work.\nIn-flight work includes activities, child workflows, Nexus operations, signal/cancel external workflow operations,\nand possibly other features added in the future.\nUser timers are not classified as in-flight work and will be skipped over; the virtual clock may also skip to the\ntime point of the registered fast forward when there is no in-flight work.\nWhen time is skipped, a WorkflowExecutionTimeSkippingTransitionedEvent will be\nadded to the workflow history to capture the state changes.\n\nFor child workflows, by default, if the parent execution is skipping time, the child execution will also skip time,\nbut a parent's fast_forward won't affect its child's execution. A flag is provided to disable propagation of the\n\"enabled\" flag to child workflows; regardless of that flag, a child workflow inherits the virtual time from the\nparent execution as its start time."
1969119691
},
1969219692
"v1TimeSkippingStatePropagation": {
1969319693
"type": "object",

openapi/openapiv3.yaml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17442,6 +17442,12 @@ components:
1744217442
setting `enabled` to true via UpdateWorkflowExecutionOptions.
1744317443
The current workflow execution is a chain of runs (retries, cron, continue-as-new);
1744417444
child workflows are separate executions, so this fast_forward won't affect them.
17445+
17446+
For a given workflow execution, only one active fast-forward is allowed at a time.
17447+
If a new fast-forward is set via UpdateWorkflowExecutionOptions before the previous
17448+
one completes, the new one will override the previous one.
17449+
If the fast-forward duration exceeds the remaining execution timeout, time will only
17450+
be fast-forwarded up to the end of the execution.
1744517451
disableChildPropagation:
1744617452
type: boolean
1744717453
description: |-
@@ -17453,7 +17459,9 @@ components:
1745317459
In-flight work includes activities, child workflows, Nexus operations, signal/cancel external workflow operations,
1745417460
and possibly other features added in the future.
1745517461
User timers are not classified as in-flight work and will be skipped over; the virtual clock may also skip to the
17456-
time point of the registered fast_forward when there is no in-flight work.
17462+
time point of the registered fast forward when there is no in-flight work.
17463+
When time is skipped, a WorkflowExecutionTimeSkippingTransitionedEvent will be
17464+
added to the workflow history to capture the state changes.
1745717465

1745817466
For child workflows, by default, if the parent execution is skipping time, the child execution will also skip time,
1745917467
but a parent's fast_forward won't affect its child's execution. A flag is provided to disable propagation of the

temporal/api/history/v1/message.proto

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -209,8 +209,8 @@ message WorkflowExecutionStartedEventAttributes {
209209
reserved 42;
210210
reserved "initial_skipped_duration";
211211

212-
// The time-skipping state propagated from a previous run of this workflow. This can be nil
213-
// if no time skipping has occurred or there is no previous run.
212+
// The time-skipping state propagated from a previous run of this workflow. This can be nil
213+
// if no time skipping has occurred or there is no previous run.
214214
temporal.api.workflow.v1.TimeSkippingStatePropagation time_skipping_state_propagation = 43;
215215

216216
}

temporal/api/workflow/v1/message.proto

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -596,7 +596,9 @@ message WorkflowExecutionOptions {
596596
// In-flight work includes activities, child workflows, Nexus operations, signal/cancel external workflow operations,
597597
// and possibly other features added in the future.
598598
// User timers are not classified as in-flight work and will be skipped over; the virtual clock may also skip to the
599-
// time point of the registered fast_forward when there is no in-flight work.
599+
// time point of the registered fast forward when there is no in-flight work.
600+
// When time is skipped, a WorkflowExecutionTimeSkippingTransitionedEvent will be
601+
// added to the workflow history to capture the state changes.
600602
//
601603
// For child workflows, by default, if the parent execution is skipping time, the child execution will also skip time,
602604
// but a parent's fast_forward won't affect its child's execution. A flag is provided to disable propagation of the
@@ -612,6 +614,12 @@ message TimeSkippingConfig {
612614
// setting `enabled` to true via UpdateWorkflowExecutionOptions.
613615
// The current workflow execution is a chain of runs (retries, cron, continue-as-new);
614616
// child workflows are separate executions, so this fast_forward won't affect them.
617+
//
618+
// For a given workflow execution, only one active fast-forward is allowed at a time.
619+
// If a new fast-forward is set via UpdateWorkflowExecutionOptions before the previous
620+
// one completes, the new one will override the previous one.
621+
// If the fast-forward duration exceeds the remaining execution timeout, time will only
622+
// be fast-forwarded up to the end of the execution.
615623
google.protobuf.Duration fast_forward = 2;
616624

617625
// By default, child workflows inherit the "enabled" flag when they are started.

0 commit comments

Comments
 (0)