Script context compilation rate changes via HTTP API do not take effect #77003
Labels
>bug
:Core/Infra/Scripting
Scripting abstractions, Painless, and Mustache
:Core/Infra/Settings
Settings infrastructure and APIs
Team:Core/Infra
Meta label for core/infra team
Elasticsearch version (
bin/elasticsearch --version
):Description of the problem including expected versus actual behavior:
Attempting to set the
script.context.template.max_compilations_rate
setting via thePUT /_cluster/settings
API (persistent and transient) does not seem to affect the setting. I scanned over the ScriptCache and ScriptService code and it looks like the setting gets cached and locked in at the time the ScriptCache is created and does not have any mechanism for receiving updates when the setting changes. I'm not familiar with the elasticsearch codebase, so my naive diagnosis could be wrong here.Steps to reproduce:
CircuitBreakingException[[script] Too many dynamic script compilations within, max: [75/5m]; please use indexed, or scripts with parameters instead; this limit can be changed by the [script.context.template.max_compilations_rate] setting]
script.context.template.max_compilations_rate
setting via PUT /_cluster/settings APIscript.context.template.max_compilations_rate
is not 75/5mThe text was updated successfully, but these errors were encountered: