Class RestoreInProgress.ShardRestoreStatus

org.elasticsearch.cluster.RestoreInProgress.ShardRestoreStatus
All Implemented Interfaces:
Writeable
Enclosing class:
RestoreInProgress

public static class RestoreInProgress.ShardRestoreStatus extends implements Writeable
Represents status of a restored shard
  • Constructor Details

    • ShardRestoreStatus

      public ShardRestoreStatus( nodeId)
      Constructs a new shard restore status in initializing state on the given node
      Parameters:
      nodeId - node id
    • ShardRestoreStatus

      public ShardRestoreStatus( nodeId, RestoreInProgress.State state)
      Constructs a new shard restore status in with specified state on the given node
      Parameters:
      nodeId - node id
      state - restore state
    • ShardRestoreStatus

      public ShardRestoreStatus( nodeId, RestoreInProgress.State state,  reason)
      Constructs a new shard restore status in with specified state on the given node with specified failure reason
      Parameters:
      nodeId - node id
      state - restore state
      reason - failure reason
  • Method Details

    • state

      public RestoreInProgress.State state()
      Returns current state
      Returns:
      current state
    • nodeId

      public  nodeId()
      Returns node id of the node where shared is getting restored
      Returns:
      node id
    • reason

      public  reason()
      Returns failure reason
      Returns:
      failure reason
    • readShardRestoreStatus

      public static RestoreInProgress.ShardRestoreStatus readShardRestoreStatus(StreamInput in) throws
      Reads restore status from stream input
      Parameters:
      in - stream input
      Returns:
      restore status
      Throws:
    • readFrom

      public void readFrom(StreamInput in) throws
      Reads restore status from stream input
      Parameters:
      in - stream input
      Throws:
    • writeTo

      public void writeTo(StreamOutput out) throws
      Writes restore status to stream output
      Specified by:
      writeTo in interface Writeable
      Parameters:
      out - stream input
      Throws:
    • equals

      public boolean equals( o)
      Overrides:
       in class 
    • hashCode

      public int hashCode()
      Overrides:
       in class