Skip to content

Conversation

MauriceVanVeen
Copy link
Member

Enabling TTLs on a stream/source/mirror would not recover previous TTLs. TTLs can be enabled but not disabled, so it must be a conscious decision to enable it. Depending on the stream size, it might take a long time to recover but it will ensure all TTLs are respected.

This is important for a KV that's mirrored, because a mirrored KV might not have TTLs enabled yet, but the origin stream has. If you want the TTLs to be respected on the mirror as well, it needs to respect both new messages with TTLs as messages that it received prior.

Signed-off-by: Maurice van Veen github@mauricevanveen.com

Signed-off-by: Maurice van Veen <github@mauricevanveen.com>
@MauriceVanVeen MauriceVanVeen requested a review from a team as a code owner July 29, 2025 19:42
Copy link
Member

@neilalexander neilalexander left a comment

Choose a reason for hiding this comment

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

LGTM

@neilalexander neilalexander merged commit ca3927a into main Jul 30, 2025
68 of 70 checks passed
@neilalexander neilalexander deleted the maurice/enable-recover-ttl branch July 30, 2025 10:20
neilalexander added a commit that referenced this pull request Jul 31, 2025
Includes the following:

* #7117
* #7123

Signed-off-by: Neil Twigg <neil@nats.io>
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.

2 participants