Add allocation deciders in createComponents (#89836)

With this change we are adding the allocation deciders
in create components we can simplify the use in the
Autoscaling plugin and implement reserved state handler
in the future.
This commit is contained in:
Nikola Grcevski 2022-09-07 09:28:07 -04:00 committed by GitHub
parent cd8a7bdea1
commit fc819609a1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
57 changed files with 172 additions and 83 deletions

View file

@ -10,6 +10,7 @@ package org.elasticsearch.runtimefields;
import org.elasticsearch.client.internal.Client;
import org.elasticsearch.cluster.metadata.IndexNameExpressionResolver;
import org.elasticsearch.cluster.routing.allocation.decider.AllocationDeciders;
import org.elasticsearch.cluster.service.ClusterService;
import org.elasticsearch.common.io.stream.NamedWriteableRegistry;
import org.elasticsearch.common.settings.Setting;
@ -74,7 +75,8 @@ public final class RuntimeFieldsCommonPlugin extends Plugin {
NamedWriteableRegistry namedWriteableRegistry,
IndexNameExpressionResolver indexNameExpressionResolver,
Supplier<RepositoriesService> repositoriesServiceSupplier,
Tracer tracer
Tracer tracer,
AllocationDeciders allocationDeciders
) {
grokHelper.finishInitializing(threadPool);
return List.of();