Skip to content

Report runtime environment information in worker heartbeats - #3052

Open
Sushisource wants to merge 2 commits into
mainfrom
environment-info-go-java
Open

Report runtime environment information in worker heartbeats#3052
Sushisource wants to merge 2 commits into
mainfrom
environment-info-go-java

Conversation

@Sushisource

Copy link
Copy Markdown
Member

What was changed

Worker heartbeats now include an EnvironmentInfo message describing the JVM version, detected hosting environments (Docker, Kubernetes, AWS Lambda/ECS, Google Cloud Run/App Engine, Azure App Service/Functions/Container Apps), and the OS platform (Linux/macOS/Windows version, architecture, and Windows CRT).

The information is attached to each worker's heartbeats until the server accepts one, then omitted. HeartbeatManager tracks pending workers and clears them only after a successful recordWorkerHeartbeat.

A new experimental WorkflowClientOptions.Builder#setDisableWorkerEnvironmentInfo turns the reporting off.

Why?

Port of Core's temporalio/sdk-rust#1457 so all SDKs report the same analytical information about the environments they run in.

Checklist

  1. Closes N/A

  2. How was this tested:

New unit tests in WorkerEnvironmentInfoTest cover live detection, hosting-environment env vars, cgroup parsing, and Java version parsing. HeartbeatManagerTest gained cases for retry-until-accepted delivery and for omitting the environment when disabled.

  1. Any docs updates needed?

No.

@Sushisource
Sushisource marked this pull request as ready for review September 1, 2026 21:49
@Sushisource
Sushisource requested a review from a team as a code owner September 1, 2026 21:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant