Skip to content

fix(config): Reject pending and delay limits below the insert batch length - #854

Merged
enochtangg merged 1 commit into
mainfrom
enochtang/fix/validate-store-limits
Nov 10, 2026
Merged

enochtangg merged 1 commit into
mainfrom
enochtang/fix/validate-store-limits

Conversation

@enochtangg

@enochtangg enochtangg commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

Taskbroker now refuses to start if max_pending_count, a topic's max_pending_activations, or max_delay_count is below insert_batch_max_length. With those values, a full batch can never be written and the consumer stops for good.

Why

The activation writer only stores a batch when pending + batch.len() is within the limit, and it never splits a batch. If the limit is below the batch length, a full batch fails the check even with an empty store. The writer retries the same batch forever and that topic's consumer stops until someone fixes the config and redeploys.

…ength

The activation writer only stores a batch when pending + batch.len() is
within the limit, and it never splits a batch. If max_pending_count (or a
topic's max_pending_activations, or max_delay_count) is below
insert_batch_max_length, a full batch can never be written, even with an
empty store. The writer retries it forever and the consumer stops. Low
traffic hides this because batches flush on the timer before they fill.

Check this at startup in normalize_and_validate. The global pending limit
is only checked when at least one consumed topic has no limit of its own.
Produce-only topics are skipped.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@enochtangg
enochtangg marked this pull request as ready for review November 10, 2026 15:13
@enochtangg
enochtangg requested a review from a team as a code owner November 10, 2026 15:13
@enochtangg
enochtangg merged commit a4f4950 into main Nov 10, 2026
27 checks passed
@enochtangg
enochtangg deleted the enochtang/fix/validate-store-limits branch November 10, 2026 16:28
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