GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||
GeezerVison is showing github.com — [improve][broker] Reduce cache retention after reads and apply retention settings at startup by lhotari · Pull Request #26627 · apache/pulsar Conversation
Member
MotivationRecently accessed managed-ledger cache entries currently receive an extra TTL extension by default, even after their expected reads have completed. For consumers keeping up with a topic, this retains already-read entries longer and increases cache occupancy without necessarily serving additional reads. Disable this recent-access extension by default to reduce that retention. Expected-read retention remains enabled, with up to five TTL extensions for entries with remaining expected reads. A comparison with 500 producers on separate connections and 20 consumers on one Key_Shared subscription showed the following results. Both configurations used the same broker code, one persistent topic, random keys, unbatched 128-byte messages, unrestricted production with at most 40 outstanding sends per producer, and a 12-million-message receive target. Only the recent-access extension setting differed.
Steady throughput uses topic counters after 20 seconds of warmup, includes only intervals with all 500 producers connected, and ends before producers disconnect. Cache size is the cache's accounting of stored data, not total heap usage. Allocation reductions were not consistent. These short runs demonstrate the benefit for this workload; they do not establish the same improvement for multiple subscriptions or lagging consumers. The broker also accepts two cache retention settings without passing them to the managed-ledger factory during initialization. Dynamic update listeners do not apply initial values, so startup configuration can silently leave the factory's defaults in effect. Correct startup propagation is necessary for the new broker default and for explicit operator settings to take effect. Modifications
Deployments that benefit from retaining recently read entries, such as repeated reads across subscriptions or redelivery, can explicitly set Verifying this changeParameterized tests capture the factory configuration during initialization and verify the new broker default, explicit enable/disable overrides, and expected-read extension limits. The startup propagation regression test fails without the factory assignments.
Does this pull request potentially affect one of the following parts:
Broker startup honors both retention settings, and recent-access TTL extension is disabled by default.
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions
merlimat
approved these changes
Uh oh!
There was an error while loading. Please reload this page.
4 of 11 tasks
dao-jun
pushed a commit
to ascentstream/pulsar
that referenced
this pull request
…ion settings at startup (apache#26627) (cherry picked from commit bed06a0)
dao-jun
pushed a commit
to ascentstream/pulsar
that referenced
this pull request
…ion settings at startup (apache#26627) (cherry picked from commit bed06a0)
dao-jun
pushed a commit
to ascentstream/pulsar
that referenced
this pull request
…ion settings at startup (apache#26627) (cherry picked from commit bed06a0)
dao-jun
added a commit
to ascentstream/pulsar
that referenced
this pull request
Brings in the base's cursor reset/GC series (checkpoint ledger sweep, batch-index-ack dirty flagging, failed-flush GC race hardening) and the persistentUnackedRangesMaxEntrySize startup validation. The only textual conflict was the add/add on ManagedLedgerClientFactoryTest — resolved by keeping both sides' tests (apache#26627's cache-extension settings plumbing tests plus the base's checkpoint maxEntrySize validation tests). ManagedCursorTest 214/214 and the merged factory test 6/6 green on the merged tree.
Radiancebobo
pushed a commit
to Radiancebobo/pulsar
that referenced
this pull request
…ion settings at startup (apache#26627)
nodece
pushed a commit
to ascentstream/pulsar
that referenced
this pull request
…ion settings at startup (apache#26627) (cherry picked from commit bed06a0) (cherry picked from commit d88d711)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
ReviewersUh oh!
There was an error while loading. Please reload this page. AssigneesNo one assignedProjectsDevelopmentSuccessfully merging this pull request may close these issues. Uh oh!
There was an error while loading. Please reload this page. Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later. | ||||||||||||
| You are visitor 01402775 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |