better method name, to correspond to addLast
This commit is contained in:
parent
d31fdccc97
commit
fe11368c89
|
@ -29,8 +29,6 @@ import org.elasticsearch.common.unit.TimeValue;
|
|||
/**
|
||||
* The cluster service allowing to both register for cluster state events ({@link ClusterStateListener})
|
||||
* and submit state update tasks ({@link ClusterStateUpdateTask}.
|
||||
*
|
||||
*
|
||||
*/
|
||||
public interface ClusterService extends LifecycleComponent<ClusterService> {
|
||||
|
||||
|
@ -57,7 +55,7 @@ public interface ClusterService extends LifecycleComponent<ClusterService> {
|
|||
/**
|
||||
* Adds a priority listener for updated cluster states.
|
||||
*/
|
||||
void addPriority(ClusterStateListener listener);
|
||||
void addFirst(ClusterStateListener listener);
|
||||
|
||||
/**
|
||||
* Adds last listener.
|
||||
|
|
|
@ -61,7 +61,7 @@ public class RoutingService extends AbstractLifecycleComponent<RoutingService> i
|
|||
this.clusterService = clusterService;
|
||||
this.allocationService = allocationService;
|
||||
this.schedule = componentSettings.getAsTime("schedule", timeValueSeconds(10));
|
||||
clusterService.addPriority(this);
|
||||
clusterService.addFirst(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -150,7 +150,7 @@ public class InternalClusterService extends AbstractLifecycleComponent<ClusterSe
|
|||
return this.clusterState;
|
||||
}
|
||||
|
||||
public void addPriority(ClusterStateListener listener) {
|
||||
public void addFirst(ClusterStateListener listener) {
|
||||
priorityClusterStateListeners.add(listener);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue