312
313
if checkWTHeartbeatTimeout {
314
>
// WorkflowTaskHeartbeatTimeout is a total duration for which workflow is allowed to send continuous heartbeats.
api.go
315
>
// Default is 30 minutes.
316
>
// Heartbeat duration is computed between now and OriginalScheduledTime, which is set when WT is scheduled and
317
>
// carried over to the consequence WTs if they are heartbeat WTs.
318
>
// After this timeout is expired, WT is timed out (although this specific WT doesn't)
319
>
// and new WT will be scheduled on non-sticky task queue (see ClearStickyTaskQueue call bellow).
320
>
wtHeartbeatTimeoutDuration := handler.config.WorkflowTaskHeartbeatTimeout(nsName)
321
>
if currentWorkflowTask.OriginalScheduledTime.UnixNano() > 0 &&
322
>
handler.timeSource.Now().After(currentWorkflowTask.OriginalScheduledTime.Add(wtHeartbeatTimeoutDuration)) {
323
324
scope := handler.metricsHandler.WithTags(