From 4a81c85f7113819bb7813f3073f91d2517c2828a Mon Sep 17 00:00:00 2001 From: Colin Goodheart-Smithe Date: Mon, 27 Feb 2017 08:43:27 +0000 Subject: [PATCH] Reapplying: Adds cast hint for eclipse MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Eclipse errors because the direct supperclass of the two listeners is package private and it doesn’t have the smarts to look higher in the heirarchy. So we need to add a cast hint to force Eclipse to consider the elements as Listeners This fix was mistakenly removed in another commit Original commit: elastic/x-pack-elasticsearch@6305456d5af9145fd7886e6e03b76d817d7bf1c9 --- .../org/elasticsearch/xpack/ml/MlInitializationService.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/plugin/src/main/java/org/elasticsearch/xpack/ml/MlInitializationService.java b/plugin/src/main/java/org/elasticsearch/xpack/ml/MlInitializationService.java index bdc951604bc..c6477251a25 100644 --- a/plugin/src/main/java/org/elasticsearch/xpack/ml/MlInitializationService.java +++ b/plugin/src/main/java/org/elasticsearch/xpack/ml/MlInitializationService.java @@ -6,7 +6,6 @@ package org.elasticsearch.xpack.ml; import org.apache.logging.log4j.message.ParameterizedMessage; -import org.elasticsearch.ResourceAlreadyExistsException; import org.elasticsearch.client.Client; import org.elasticsearch.cluster.ClusterChangedEvent; import org.elasticsearch.cluster.ClusterState; @@ -181,7 +180,7 @@ public class MlInitializationService extends AbstractComponent implements Cluste private void installDailyManagementService() { if (mlDailyManagementService == null) { - mlDailyManagementService = new MlDailyManagementService(threadPool, Arrays.asList( + mlDailyManagementService = new MlDailyManagementService(threadPool, Arrays.asList((MlDailyManagementService.Listener) new ExpiredResultsRemover(client, clusterService, auditor), new ExpiredModelSnapshotsRemover(client, clusterService) ));