Scripting: Per-context script cache, default off (#52855) #53756
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.
Adds per context settings:
script.context.${CONTEXT}.cache_max_size
~script.cache.max_size
script.context.${CONTEXT}.cache_expire
~script.cache.expire
script.context.${CONTEXT}.max_compilations_rate
~script.max_compilations_rate
Context cache is used if:
script.max_compilations_rate=use-context
. Thisvalue is dynamically updatable, so users can
switch back to the general cache if desired.
Settings for context caches take the first value
that applies:
script.context.ingest.cache_max_size
value, eg
script.cache.max_size
The reason for 2's inclusion is to allow an easy
transition for users who've customized their general
cache settings.
Using the general cache settings for the context caches
results in higher effective settings, since they are
multiplied across the number of contexts. So a general
cache max size of 200 will become 200 * # of contexts.
However, this behavior it will avoid users snapping to a
value that is too low for them.
Backport of: #52855
Refs: #50152