Class RestoreInProgress.ShardRestoreStatus

  • Enclosing class:
    RestoreInProgress

    public static class RestoreInProgress.ShardRestoreStatus
    extends java.lang.Object
    Represents status of a restored shard
    • Constructor Detail

      • ShardRestoreStatus

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

        public ShardRestoreStatus​(java.lang.String 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​(java.lang.String nodeId,
                                  RestoreInProgress.State state,
                                  java.lang.String 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 Detail

      • nodeId

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

        public java.lang.String reason()
        Returns failure reason
        Returns:
        failure reason
      • readShardRestoreStatus

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

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

        public void writeTo​(StreamOutput out)
                     throws java.io.IOException
        Writes restore status to stream output
        Parameters:
        out - stream input
        Throws:
        java.io.IOException
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object