diff --git a/x-pack/plugin/core/src/main/java/org/elasticsearch/xpack/core/indexlifecycle/AllocationRoutedStep.java b/x-pack/plugin/core/src/main/java/org/elasticsearch/xpack/core/indexlifecycle/AllocationRoutedStep.java index 560029ba857..04c9632467a 100644 --- a/x-pack/plugin/core/src/main/java/org/elasticsearch/xpack/core/indexlifecycle/AllocationRoutedStep.java +++ b/x-pack/plugin/core/src/main/java/org/elasticsearch/xpack/core/indexlifecycle/AllocationRoutedStep.java @@ -7,6 +7,7 @@ package org.elasticsearch.xpack.core.indexlifecycle; import com.carrotsearch.hppc.cursors.ObjectCursor; +import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import org.elasticsearch.action.support.ActiveShardCount; import org.elasticsearch.cluster.ClusterState; @@ -20,7 +21,6 @@ import org.elasticsearch.cluster.routing.allocation.decider.FilterAllocationDeci import org.elasticsearch.common.ParseField; import org.elasticsearch.common.Strings; import org.elasticsearch.common.collect.ImmutableOpenIntMap; -import org.elasticsearch.common.logging.ESLoggerFactory; import org.elasticsearch.common.settings.ClusterSettings; import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.xcontent.ConstructingObjectParser; @@ -36,7 +36,7 @@ import java.util.Objects; public class AllocationRoutedStep extends ClusterStateWaitStep { public static final String NAME = "check-allocation"; - private static final Logger logger = ESLoggerFactory.getLogger(AllocationRoutedStep.class); + private static final Logger logger = LogManager.getLogger(AllocationRoutedStep.class); private static final AllocationDeciders ALLOCATION_DECIDERS = new AllocationDeciders(Settings.EMPTY, Collections.singletonList( new FilterAllocationDecider(Settings.EMPTY, new ClusterSettings(Settings.EMPTY, ClusterSettings.BUILT_IN_CLUSTER_SETTINGS)))); diff --git a/x-pack/plugin/core/src/main/java/org/elasticsearch/xpack/core/indexlifecycle/LifecyclePolicy.java b/x-pack/plugin/core/src/main/java/org/elasticsearch/xpack/core/indexlifecycle/LifecyclePolicy.java index 6e01d0ff0f3..abf46df9a16 100644 --- a/x-pack/plugin/core/src/main/java/org/elasticsearch/xpack/core/indexlifecycle/LifecyclePolicy.java +++ b/x-pack/plugin/core/src/main/java/org/elasticsearch/xpack/core/indexlifecycle/LifecyclePolicy.java @@ -5,6 +5,7 @@ */ package org.elasticsearch.xpack.core.indexlifecycle; +import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import org.elasticsearch.client.Client; import org.elasticsearch.cluster.AbstractDiffable; @@ -13,7 +14,6 @@ import org.elasticsearch.common.ParseField; import org.elasticsearch.common.Strings; import org.elasticsearch.common.io.stream.StreamInput; import org.elasticsearch.common.io.stream.StreamOutput; -import org.elasticsearch.common.logging.ESLoggerFactory; import org.elasticsearch.common.xcontent.ConstructingObjectParser; import org.elasticsearch.common.xcontent.ToXContentObject; import org.elasticsearch.common.xcontent.XContentBuilder; @@ -40,7 +40,7 @@ import java.util.stream.Collectors; */ public class LifecyclePolicy extends AbstractDiffable implements ToXContentObject, Diffable { - private static final Logger logger = ESLoggerFactory.getLogger(LifecyclePolicy.class); + private static final Logger logger = LogManager.getLogger(LifecyclePolicy.class); public static final ParseField PHASES_FIELD = new ParseField("phases"); diff --git a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/ExecuteStepsUpdateTask.java b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/ExecuteStepsUpdateTask.java index 48e65a40a24..e9d35da5434 100644 --- a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/ExecuteStepsUpdateTask.java +++ b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/ExecuteStepsUpdateTask.java @@ -6,12 +6,12 @@ package org.elasticsearch.xpack.indexlifecycle; +import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import org.elasticsearch.ElasticsearchException; import org.elasticsearch.cluster.ClusterState; import org.elasticsearch.cluster.ClusterStateUpdateTask; import org.elasticsearch.cluster.metadata.IndexMetaData; -import org.elasticsearch.common.logging.ESLoggerFactory; import org.elasticsearch.common.xcontent.ToXContentObject; import org.elasticsearch.index.Index; import org.elasticsearch.xpack.core.indexlifecycle.ClusterStateActionStep; @@ -22,7 +22,7 @@ import java.io.IOException; import java.util.function.LongSupplier; public class ExecuteStepsUpdateTask extends ClusterStateUpdateTask { - private static final Logger logger = ESLoggerFactory.getLogger(ExecuteStepsUpdateTask.class); + private static final Logger logger = LogManager.getLogger(ExecuteStepsUpdateTask.class); private final String policy; private final Index index; private final Step startStep; diff --git a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/IndexLifecycleRunner.java b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/IndexLifecycleRunner.java index 7b91a42ff64..076a25c7d25 100644 --- a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/IndexLifecycleRunner.java +++ b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/IndexLifecycleRunner.java @@ -6,6 +6,7 @@ package org.elasticsearch.xpack.indexlifecycle; import com.carrotsearch.hppc.cursors.ObjectCursor; +import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import org.elasticsearch.ElasticsearchException; import org.elasticsearch.action.support.TransportAction; @@ -15,7 +16,6 @@ import org.elasticsearch.cluster.metadata.MetaData; import org.elasticsearch.cluster.service.ClusterService; import org.elasticsearch.common.Strings; import org.elasticsearch.common.bytes.BytesReference; -import org.elasticsearch.common.logging.ESLoggerFactory; import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.xcontent.ToXContent; import org.elasticsearch.common.xcontent.ToXContentObject; @@ -43,7 +43,7 @@ import java.util.Map; import java.util.function.LongSupplier; public class IndexLifecycleRunner { - private static final Logger logger = ESLoggerFactory.getLogger(IndexLifecycleRunner.class); + private static final Logger logger = LogManager.getLogger(IndexLifecycleRunner.class); private PolicyStepsRegistry stepRegistry; private ClusterService clusterService; private LongSupplier nowSupplier; diff --git a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/IndexLifecycleService.java b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/IndexLifecycleService.java index 8e5e70c0939..2ea924b9608 100644 --- a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/IndexLifecycleService.java +++ b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/IndexLifecycleService.java @@ -7,6 +7,7 @@ package org.elasticsearch.xpack.indexlifecycle; import com.carrotsearch.hppc.cursors.ObjectCursor; +import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import org.apache.lucene.util.SetOnce; import org.elasticsearch.client.Client; @@ -18,7 +19,6 @@ import org.elasticsearch.cluster.metadata.IndexMetaData; import org.elasticsearch.cluster.service.ClusterService; import org.elasticsearch.common.Strings; import org.elasticsearch.common.component.AbstractComponent; -import org.elasticsearch.common.logging.ESLoggerFactory; import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.unit.TimeValue; import org.elasticsearch.protocol.xpack.indexlifecycle.OperationMode; @@ -40,7 +40,7 @@ import java.util.function.LongSupplier; */ public class IndexLifecycleService extends AbstractComponent implements ClusterStateListener, ClusterStateApplier, SchedulerEngine.Listener, Closeable { - private static final Logger logger = ESLoggerFactory.getLogger(IndexLifecycleService.class); + private static final Logger logger = LogManager.getLogger(IndexLifecycleService.class); private static final Set IGNORE_ACTIONS_MAINTENANCE_REQUESTED = Collections.singleton(ShrinkAction.NAME); private final SetOnce scheduler = new SetOnce<>(); diff --git a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/OperationModeUpdateTask.java b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/OperationModeUpdateTask.java index 871a782a9ac..0bd8e351351 100644 --- a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/OperationModeUpdateTask.java +++ b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/OperationModeUpdateTask.java @@ -5,16 +5,16 @@ */ package org.elasticsearch.xpack.indexlifecycle; +import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import org.elasticsearch.cluster.ClusterState; import org.elasticsearch.cluster.ClusterStateUpdateTask; import org.elasticsearch.cluster.metadata.MetaData; -import org.elasticsearch.common.logging.ESLoggerFactory; import org.elasticsearch.protocol.xpack.indexlifecycle.OperationMode; import org.elasticsearch.xpack.core.indexlifecycle.IndexLifecycleMetadata; public class OperationModeUpdateTask extends ClusterStateUpdateTask { - private static final Logger logger = ESLoggerFactory.getLogger(OperationModeUpdateTask.class); + private static final Logger logger = LogManager.getLogger(OperationModeUpdateTask.class); private final OperationMode mode; public OperationModeUpdateTask(OperationMode mode) { diff --git a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/PolicyStepsRegistry.java b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/PolicyStepsRegistry.java index c486592c637..2715b9ae09b 100644 --- a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/PolicyStepsRegistry.java +++ b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/PolicyStepsRegistry.java @@ -6,6 +6,7 @@ package org.elasticsearch.xpack.indexlifecycle; import com.carrotsearch.hppc.cursors.ObjectCursor; +import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import org.elasticsearch.client.Client; import org.elasticsearch.cluster.ClusterState; @@ -15,7 +16,6 @@ import org.elasticsearch.cluster.metadata.IndexMetaData; import org.elasticsearch.common.Nullable; import org.elasticsearch.common.io.stream.StreamInput; import org.elasticsearch.common.io.stream.StreamOutput; -import org.elasticsearch.common.logging.ESLoggerFactory; import org.elasticsearch.index.Index; import org.elasticsearch.xpack.core.ClientHelper; import org.elasticsearch.xpack.core.indexlifecycle.ErrorStep; @@ -34,7 +34,7 @@ import java.util.function.LongSupplier; import java.util.stream.Collectors; public class PolicyStepsRegistry { - private static final Logger logger = ESLoggerFactory.getLogger(PolicyStepsRegistry.class); + private static final Logger logger = LogManager.getLogger(PolicyStepsRegistry.class); // keeps track of existing policies in the cluster state private final SortedMap lifecyclePolicyMap;