Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a little detail on when heartbeat is seen from the activity side #650

Merged
merged 3 commits into from
Dec 3, 2021

Conversation

cretz
Copy link
Member

@cretz cretz commented Nov 23, 2021

What was changed

Make clear an why activity context doesn't see its cancellation immediately without documenting too many details.

Why?

It is otherwise unclear when an activity can see its cancellation.

Checklist

  1. Closes Document about and warn when attempting to use activity cancellation/heartbeats without HeartbeatTimeout #638

// *CanceledError set as cause for *ActivityError.
// *CanceledError set as cause for *ActivityError. The context in the activity only becomes aware of the cancellation
// when a heartbeat is sent to the server. Since heartbeats may be batched internally, this could take up to the
// HeartbeatTimeout to appear or several minutes by default if that value is not set.
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technically it's only 80% of the timeout and technically the default is 10 minutes, but we leave that implementation detail out of the docs.

@cretz cretz merged commit 7125db9 into temporalio:master Dec 3, 2021
@cretz cretz deleted the heartbeat-doc branch December 3, 2021 16:32
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.

Document about and warn when attempting to use activity cancellation/heartbeats without HeartbeatTimeout
2 participants