Table of Contents

Class TimeSkippingConfig

Namespace
Temporalio.Api.Common.V1
Assembly
Temporalio.dll

The configuration for time skipping of 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. User timers are not classified as in-flight work and will be skipped over; the virtual clock may also skip to the time point of the registered fast forward when there is no in-flight work. When time is skipped, a WorkflowExecutionTimeSkippingTransitionedEvent will be added to the workflow history to capture the state changes.

For child workflows, by default, if the parent execution is skipping time, the child execution will also skip time, 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.

public sealed class TimeSkippingConfig : IMessage<TimeSkippingConfig>, IEquatable<TimeSkippingConfig>, IDeepCloneable<TimeSkippingConfig>, IBufferMessage, IMessage
Inheritance
TimeSkippingConfig
Implements
IDeepCloneable<TimeSkippingConfig>
IBufferMessage
IMessage
Inherited Members

Constructors

TimeSkippingConfig()

public TimeSkippingConfig()

TimeSkippingConfig(TimeSkippingConfig)

public TimeSkippingConfig(TimeSkippingConfig other)

Parameters

other TimeSkippingConfig

Fields

DisableChildPropagationFieldNumber

Field number for the "disable_child_propagation" field.

public const int DisableChildPropagationFieldNumber = 3

Field Value

int

EnabledFieldNumber

Field number for the "enabled" field.

public const int EnabledFieldNumber = 1

Field Value

int

FastForwardFieldNumber

Field number for the "fast_forward" field.

public const int FastForwardFieldNumber = 2

Field Value

int

Properties

Descriptor

public static MessageDescriptor Descriptor { get; }

Property Value

MessageDescriptor

DisableChildPropagation

By default, child workflows inherit the "enabled" flag when they are started. This flag disables that inheritance.

public bool DisableChildPropagation { get; set; }

Property Value

bool

Enabled

Enables or disables time skipping for this workflow execution.

public bool Enabled { get; set; }

Property Value

bool

FastForward

Optionally fast-forward the current workflow execution by this duration ahead of current workflow execution time. After the fast-forward completes, time skipping is disabled, and this action is recorded in the WorkflowExecutionTimeSkippingTransitionedEvent. It can be re-enabled by setting enabled to true or setting fast_forward again 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 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.

public Duration FastForward { get; set; }

Property Value

Duration

Parser

public static MessageParser<TimeSkippingConfig> Parser { get; }

Property Value

MessageParser<TimeSkippingConfig>

Methods

CalculateSize()

Calculates the size of this message in Protocol Buffer wire format, in bytes.

public int CalculateSize()

Returns

int

The number of bytes required to write this message to a coded output stream.

Clone()

Creates a deep clone of this object.

public TimeSkippingConfig Clone()

Returns

TimeSkippingConfig

A deep clone of this object.

Equals(object)

Determines whether the specified object is equal to the current object.

public override bool Equals(object other)

Parameters

other object

Returns

bool

true if the specified object is equal to the current object; otherwise, false.

Equals(TimeSkippingConfig)

Indicates whether the current object is equal to another object of the same type.

public bool Equals(TimeSkippingConfig other)

Parameters

other TimeSkippingConfig

An object to compare with this object.

Returns

bool

true if the current object is equal to the other parameter; otherwise, false.

GetHashCode()

Serves as the default hash function.

public override int GetHashCode()

Returns

int

A hash code for the current object.

MergeFrom(CodedInputStream)

Merges the data from the specified coded input stream with the current message.

public void MergeFrom(CodedInputStream input)

Parameters

input CodedInputStream

Remarks

See the user guide for precise merge semantics.

MergeFrom(TimeSkippingConfig)

Merges the given message into this one.

public void MergeFrom(TimeSkippingConfig other)

Parameters

other TimeSkippingConfig

Remarks

See the user guide for precise merge semantics.

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.

WriteTo(CodedOutputStream)

Writes the data to the given coded output stream.

public void WriteTo(CodedOutputStream output)

Parameters

output CodedOutputStream

Coded output stream to write the data to. Must not be null.