Skip to content

Fix for notifier retrying without backoff when context reaches deadline - #1495

Merged
brandur merged 1 commit into
masterfrom
brandur-notifier-flood-fix
Oct 12, 2026
Merged

brandur merged 1 commit into
masterfrom
brandur-notifier-flood-fix

Conversation

@brandur

@brandur brandur commented Oct 10, 2026

Copy link
Copy Markdown
Contributor

Fixes #1493. A notifier connecting after its context deadline was
reached would enter a hot loop, retry forever, and flood logs while
doing so. Fix is to make sure there's a check on ctx.Err().

Fixes #1493. A notifier connecting after its context deadline was
reached would enter a hot loop, retry forever, and flood logs while
doing so. Fix is to make sure there's a check on `ctx.Err()`.
@brandur
brandur force-pushed the brandur-notifier-flood-fix branch from ef8452e to 3570664 Compare October 10, 2026 19:46

@nooby6 nooby6 left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

I reviewed the retry-loop change and its added tests. The important distinction is checking the service context (ctx.Err()) rather than classifying the returned operation error: a listener operation can return a wrapped cancellation/deadline while the service context is still live, and that should not stop the notifier. The ListenerDeadlineExceeded case exercises that boundary, while the service-context cancellation/deadline cases cover shutdown. I don't see a blocking correctness issue in this diff.

@brandur

brandur commented Oct 12, 2026

Copy link
Copy Markdown
Contributor Author

thx!

@brandur
brandur merged commit ecd23e8 into master Oct 12, 2026
23 checks passed
@brandur
brandur deleted the brandur-notifier-flood-fix branch October 12, 2026 20:18
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.

Notifier spins without backoff when the Start context ends by deadline

3 participants