Will Duan 5ed21eb39b Preserve pending heartbeat timeout task during replication (#11811)
## Summary

- preserve the local heartbeat timer-task status when replicated
heartbeat progress only moves the deadline later
- continue invalidating the status for a new activity attempt, options
stamp, or cross-cluster version
- prevent passive task refresh from creating a duplicate heartbeat
timeout task while an earlier valid wake-up is already pending

## Why

The active path coalesces heartbeat timeout tasks: recording a heartbeat
keeps the earlier pending wake-up, which re-evaluates the latest
heartbeat deadline when it fires. State-based replication previously
cleared that timer status when the heartbeat deadline moved, causing
passive task refresh to create an extra timeout task.

## Testing

- `go test ./service/history/workflow -run "^TestMutableStateSuite$"
-testify.m "^TestNextActivityTimerTaskMask_" -count=1`
- verified with replication multiple batches both enabled and disabled
2026-08-28 11:19:35 -07:00
2026-08-28 10:54:48 +00:00
2026-08-26 10:00:40 -07:00
2026-08-26 10:00:40 -07:00
2025-04-07 18:42:37 -07:00

Temporal—durable execution platform

GitHub Release GitHub License Code Coverage Community Go Report Card

Introduction   •   Getting Started   •   Contributing   •   Temporal Docs   •   Temporal 101

Introduction

Temporal is a durable execution platform that enables developers to build scalable applications without sacrificing productivity or reliability. The Temporal server executes units of application logic called Workflows in a resilient manner that automatically handles intermittent failures, and retries failed operations.

Temporal is a mature technology that originated as a fork of Uber's Cadence. It is developed by Temporal Technologies, a startup by the creators of Cadence.

image

Getting Started

Download and Start Temporal Server Locally

Execute the following commands to start a pre-built image along with all the dependencies.

brew install temporal
temporal server start-dev

Refer to Temporal CLI documentation for more installation options.

Run the Samples

Clone or download samples for Go or Java and run them with the local Temporal server. We have a number of HelloWorld type scenarios available, as well as more advanced ones. Note that the sets of samples are currently different between Go and Java.

Use CLI

Use Temporal CLI to interact with the running Temporal server.

temporal operator namespace list
temporal workflow list

Use Temporal Web UI

Try Temporal Web UI by opening http://localhost:8233 for viewing your sample workflows executing on Temporal.

Repository

This repository contains the source code of the Temporal server. To implement Workflows, Activities and Workers, use one of the supported languages.

Contributing

We'd love your help in making Temporal great.

Helpful links to get started:

License

MIT License

Languages
Go 99.5%
Shell 0.2%
PLpgSQL 0.2%
Makefile 0.1%