Skip to content

Conversation

@yycptt
Copy link
Member

@yycptt yycptt commented Jan 6, 2026

What changed?

  • Do not update CloseTime on standby
  • Generate retention timer on standby as long as execution is not previously closed.

Why?

  • Previous logic won't generate retention timer on standby side if there are state transitions after execution close and those transitions get replicated together with the transition that closes the execution.

How did you test it?

  • built
  • run locally and tested manually
  • covered by existing tests
  • added new unit test(s)
  • added new functional test(s)

@yycptt yycptt requested review from a team as code owners January 6, 2026 09:20
@yycptt yycptt mentioned this pull request Jan 6, 2026
5 tasks
@yycptt
Copy link
Member Author

yycptt commented Jan 6, 2026

I actually have a xdc retention timer functional test here passing as well.

But today we have a hardcoded minimal retention period and I have to overwrite for the tests to work. So that's not ready for merging yet.

transactionPolicy historyi.TransactionPolicy,
) error {

if !isStateDirty ||
Copy link
Member Author

Choose a reason for hiding this comment

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

it's fine to check isStateDirty as well (since state changed to close means the root component state must have changed), but not really necessary, we only need to look at current state and state in db.

@yycptt yycptt enabled auto-merge (squash) January 6, 2026 10:44
@yycptt yycptt disabled auto-merge January 6, 2026 18:00
@yycptt yycptt merged commit 5b7662b into temporalio:main Jan 6, 2026
136 of 140 checks passed
@yycptt yycptt deleted the chasm-fix-standby-retention-timer branch January 6, 2026 20:42
@awln-temporal awln-temporal self-requested a review January 7, 2026 00:26
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.

3 participants