Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 14 additions & 2 deletions openapi/openapiv2.json
Original file line number Diff line number Diff line change
Expand Up @@ -18613,6 +18613,10 @@
},
"state": {
"$ref": "#/definitions/v1ScheduleState"
},
"timeSkippingConfig": {
"$ref": "#/definitions/v1TimeSkippingConfig",
"description": "Time-skipping configuration for this schedule.\nIf not set, time skipping is disabled for triggered actions."
}
}
},
Expand Down Expand Up @@ -18814,6 +18818,10 @@
},
"unpause": {
"type": "string"
},
"timeSkippingConfig": {
"$ref": "#/definitions/v1TimeSkippingConfig",
"description": "If set, updates the time-skipping configuration for this schedule."
}
}
},
Expand Down Expand Up @@ -19676,14 +19684,18 @@
},
"fastForward": {
"type": "string",
"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."
"description": "Optionally fast-forward the current execution by this duration ahead of current execution time.\nFor a given execution, only one active fast-forward is allowed at a time.\nIf a new fast-forward is set via a update call 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.\n\nIf the executions are workflows:\nWhen the fast-forward completes, time skipping is disabled by the call that initiated\nthe fast-forward, and this action is recorded in the WorkflowExecutionTimeSkippingTransitionedEvent.\nIt can be re-enabled by setting `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."
},
"disableChildPropagation": {
"type": "boolean",
"description": "By default, child workflows inherit the \"enabled\" flag when they are started.\nThis flag disables that inheritance."
},
"disableScheduledActionPropagation": {
"type": "boolean",
"description": "By default, executions inherit the \"enabled\" flag when they are started by a scheduler.\nThis flag disables that inheritance."
}
},
"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."
"description": "The configuration for time skipping of an execution.\n\nFor 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.\n\nFor a scheduler execution: {{ TBD }}"
},
"v1TimeSkippingStatePropagation": {
"type": "object",
Expand Down
40 changes: 30 additions & 10 deletions openapi/openapiv3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15591,6 +15591,12 @@ components:
$ref: '#/components/schemas/SchedulePolicies'
state:
$ref: '#/components/schemas/ScheduleState'
timeSkippingConfig:
allOf:
- $ref: '#/components/schemas/TimeSkippingConfig'
description: |-
Time-skipping configuration for this schedule.
If not set, time skipping is disabled for triggered actions.
ScheduleAction:
type: object
properties:
Expand Down Expand Up @@ -15760,6 +15766,10 @@ components:
notes field to the value of the string.
unpause:
type: string
timeSkippingConfig:
allOf:
- $ref: '#/components/schemas/TimeSkippingConfig'
description: If set, updates the time-skipping configuration for this schedule.
SchedulePolicies:
type: object
properties:
Expand Down Expand Up @@ -17433,25 +17443,33 @@ components:
pattern: ^-?(?:0|[1-9][0-9]{0,11})(?:\.[0-9]{1,9})?s$
type: string
description: |-
Optionally fast-forward the current workflow execution by this duration ahead of current workflow execution time.
When the fast-forward completes, time skipping is disabled by the call that initiated the fast-forward, and this
action is recorded in the WorkflowExecutionTimeSkippingTransitionedEvent. It can be re-enabled by
setting `enabled` to true via UpdateWorkflowExecutionOptions.
The current workflow execution is a chain of runs (retries, cron, continue-as-new);
child workflows are separate executions, so this fast_forward won't affect them.

For a given workflow execution, only one active fast-forward is allowed at a time.
If a new fast-forward is set via UpdateWorkflowExecutionOptions before the previous
Optionally fast-forward the current execution by this duration ahead of current execution time.
For a given execution, only one active fast-forward is allowed at a time.
If a new fast-forward is set via a update call before the previous
one completes, the new one will override the previous one.
If the fast-forward duration exceeds the remaining execution timeout, time will only
be fast-forwarded up to the end of the execution.

If the executions are workflows:
When the fast-forward completes, time skipping is disabled by the call that initiated
the fast-forward, and this action is recorded in the WorkflowExecutionTimeSkippingTransitionedEvent.
It can be re-enabled by setting `enabled` to true via UpdateWorkflowExecutionOptions.
The current workflow execution is a chain of runs (retries, cron, continue-as-new);
child workflows are separate executions, so this fast_forward won't affect them.
disableChildPropagation:
type: boolean
description: |-
By default, child workflows inherit the "enabled" flag when they are started.
This flag disables that inheritance.
disableScheduledActionPropagation:
type: boolean
description: |-
By default, executions inherit the "enabled" flag when they are started by a scheduler.
This flag disables that inheritance.
description: |-
The configuration for time skipping of a workflow execution (a chain of runs including retries, cron, continue-as-new).
The configuration for time skipping of an execution.

For a workflow execution (a chain of runs including retries, cron, continue-as-new):
When time skipping is enabled, virtual time advances automatically whenever there is no in-flight work.
In-flight work includes activities, child workflows, Nexus operations, signal/cancel external workflow operations,
and possibly other features added in the future.
Expand All @@ -17464,6 +17482,8 @@ components:
but a parent's fast_forward won't affect its child's execution. A flag is provided to disable propagation of the
"enabled" flag to child workflows; regardless of that flag, a child workflow inherits the virtual time from the
parent execution as its start time.

For a scheduler execution: {{ TBD }}
TimeSkippingStatePropagation:
type: object
properties:
Expand Down
29 changes: 19 additions & 10 deletions temporal/api/common/v1/message.proto
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,9 @@ message OnConflictOptions {
bool attach_links = 3;
}

// The configuration for time skipping of a workflow execution (a chain of runs including retries, cron, continue-as-new).
// The configuration for time skipping of an execution.
//
// For a workflow execution (a chain of runs including retries, cron, continue-as-new):
// When time skipping is enabled, virtual time advances automatically whenever there is no in-flight work.
// In-flight work includes activities, child workflows, Nexus operations, signal/cancel external workflow operations,
// and possibly other features added in the future.
Expand All @@ -408,27 +410,34 @@ message OnConflictOptions {
// but a parent's fast_forward won't affect its child's execution. A flag is provided to disable propagation of the
// "enabled" flag to child workflows; regardless of that flag, a child workflow inherits the virtual time from the
// parent execution as its start time.
//
// For a scheduler execution: {{ TBD }}
message TimeSkippingConfig {
// Enables or disables time skipping for this workflow execution.
bool enabled = 1;

// Optionally fast-forward the current workflow execution by this duration ahead of current workflow execution time.
// When the fast-forward completes, time skipping is disabled by the call that initiated the fast-forward, and this
// action is recorded in the WorkflowExecutionTimeSkippingTransitionedEvent. It can be re-enabled by
// setting `enabled` to true via UpdateWorkflowExecutionOptions.
// The current workflow execution is a chain of runs (retries, cron, continue-as-new);
// child workflows are separate executions, so this fast_forward won't affect them.
//
// For a given workflow execution, only one active fast-forward is allowed at a time.
// If a new fast-forward is set via UpdateWorkflowExecutionOptions before the previous
// Optionally fast-forward the current execution by this duration ahead of current execution time.
// For a given execution, only one active fast-forward is allowed at a time.
// If a new fast-forward is set via a update call before the previous
// one completes, the new one will override the previous one.
// If the fast-forward duration exceeds the remaining execution timeout, time will only
// be fast-forwarded up to the end of the execution.
//
// If the executions are workflows:
// When the fast-forward completes, time skipping is disabled by the call that initiated
// the fast-forward, and this action is recorded in the WorkflowExecutionTimeSkippingTransitionedEvent.
// It can be re-enabled by setting `enabled` to true via UpdateWorkflowExecutionOptions.
// The current workflow execution is a chain of runs (retries, cron, continue-as-new);
// child workflows are separate executions, so this fast_forward won't affect them.
google.protobuf.Duration fast_forward = 2;

// By default, child workflows inherit the "enabled" flag when they are started.
// This flag disables that inheritance.
bool disable_child_propagation = 3;

// By default, executions inherit the "enabled" flag when they are started by a scheduler.
// This flag disables that inheritance.
bool disable_scheduled_action_propagation = 4;
}

// The time-skipping state that needs to be propagated from a parent workflow to a child workflow,
Expand Down
7 changes: 7 additions & 0 deletions temporal/api/schedule/v1/message.proto
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,9 @@ message SchedulePatch {
// notes field to the value of the string.
string pause = 3;
string unpause = 4;

// If set, updates the time-skipping configuration for this schedule.
temporal.api.common.v1.TimeSkippingConfig time_skipping_config = 5;
}

message ScheduleInfo {
Expand Down Expand Up @@ -359,6 +362,10 @@ message Schedule {
ScheduleAction action = 2;
SchedulePolicies policies = 3;
ScheduleState state = 4;

// Time-skipping configuration for this schedule.
// If not set, time skipping is disabled for triggered actions.
temporal.api.common.v1.TimeSkippingConfig time_skipping_config = 5;
}

// ScheduleListInfo is an abbreviated set of values from Schedule and ScheduleInfo
Expand Down
Loading