306
// and if the workflow is at the correct state and status to skip time.
307
// And if there is a time point to skip to is not the scope of this method.
308
>
func (ms *MutableStateImpl) isWorkflowSkippable() bool {
timeskipping.go
309
>
noSkippingReason := ""
310
>
defer func() {
311
>
if noSkippingReason != "" {
312
>
ms.logger.Debug(fmt.Sprintf("time skipping skipped for: %s", noSkippingReason),
313
>
tag.WorkflowID(ms.GetExecutionInfo().WorkflowId),
314
>
tag.WorkflowRunID(ms.GetExecutionState().RunId),
315
>
)
316
>
}
317
}()
318
319
// (1) gate by time skipping configuration
320
>
tsc := ms.GetExecutionInfo().GetTimeSkippingInfo().GetConfig()
timeskipping.go
321
>
if tsc == nil || !tsc.Enabled {
322
>
noSkippingReason = "time skipping is not enabled"
323
>
return false
324
>
}
325
326
// (2) gate by workflow state and status