Interface ClusterApplier

All Known Implementing Classes:
ClusterApplierService

public interface ClusterApplier
  • Method Details

    • setInitialState

      void setInitialState(ClusterState initialState)
      Sets the initial state for this applier. Should only be called once.
      Parameters:
      initialState - the initial state to set
    • onNewClusterState

      void onNewClusterState(String source, Supplier<ClusterState> clusterStateSupplier, ActionListener<Void> listener)
      Method to invoke when a new cluster state is available to be applied
      Parameters:
      source - information where the cluster state came from
      clusterStateSupplier - the cluster state supplier which provides the latest cluster state to apply
      listener - notified after cluster state is applied. The implementation must not throw exceptions: an exception thrown by this listener is logged by the cluster applier service at ERROR level and otherwise ignored, except in tests where it raises an AssertionError. If log-and-ignore is the right behaviour then implementations must do so themselves, typically using a more specific logger and at a less dramatic log level.
    • getStats