-
Notifications
You must be signed in to change notification settings - Fork 8.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Elasticsearch config run-time updates #40188
Comments
For the legacy elasticsearch-js, I think we have to do this to support log rotation. As far as I know (but I could be wrong), logging configuration for the legacy esjs client is handled via constructor arguments, so when someone sends a This won't be necessary when things switch over to the new elasticsearch-js client which doesn't have built in logging and instead relies on you hooking into an event emitter. |
IIRC, during SIGHUP we reload only The only ES client specific logging option is |
If that is indeed the case, then ignore my comment. |
What config options are subjects for updating @epixa @joshdover ? If it is only - legacy: { config$ }
- adminClient$: clients$.pipe(map(clients => clients.adminClient)),
- dataClient$: clients$.pipe(map(clients => clients.dataClient)),
+ legacy: { config }
+ adminClient,
+ dataClient, And support function getLoggerClass(log: Logger, logQueries$) {
return class ElasticsearchClientLogging {
private logQueries: boolean;
constructor(){
this.logQueries = false;
logQueries$.subscribe(logQueries => this.logQueries = logQueries)
} |
How new |
Side note: it doesn't matter too much at this point, but once/if we migrate to the new logging system/config we may not need # equals to elasticsearch.logQueries: true
loggers:
- context: elasticsearch-queries
level: trace
# equals to elasticsearch.logQueries: false
loggers:
- context: elasticsearch-queries
level: off |
created #41956 |
In New Platform createCluster, a part of
ElasticSearchService
, requires to pass the whole config to create a new client. This leads to config leakage.Probably that was done because the config is a stream and
createCluster
returns created client immediately. already implementedcreateCluster
method as another stream of clients. That makes all the calling code asynchronous and may complicate migration.@elastic/kibana-platform do we want to support client recreation when elasticsearch config was updated? we need to unify all client contracts and decided whether we expose them as streams or imperative sync calls.
The text was updated successfully, but these errors were encountered: