java.lang.Object
org.elasticsearch.cluster.routing.allocation.FailedShard

public class FailedShard
extends java.lang.Object
A class representing a failed shard.
  • Constructor Summary

    Constructors
    Constructor Description
    FailedShard​(ShardRouting routingEntry, java.lang.String message, java.lang.Exception failure, boolean markAsStale)  
  • Method Summary

    Modifier and Type Method Description
    java.lang.Exception getFailure()
    The exception, if present, causing the shard to fail.
    java.lang.String getMessage()
    The failure message, if available, explaining why the shard failed.
    ShardRouting getRoutingEntry()
    The shard routing entry for the failed shard.
    boolean markAsStale()
    Whether or not to mark the shard as stale (eg.
    java.lang.String toString()  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • FailedShard

      public FailedShard​(ShardRouting routingEntry, java.lang.String message, @Nullable java.lang.Exception failure, boolean markAsStale)
  • Method Details

    • toString

      public java.lang.String toString()
      Overrides:
      toString in class java.lang.Object
    • getRoutingEntry

      public ShardRouting getRoutingEntry()
      The shard routing entry for the failed shard.
    • getMessage

      @Nullable public java.lang.String getMessage()
      The failure message, if available, explaining why the shard failed.
    • getFailure

      @Nullable public java.lang.Exception getFailure()
      The exception, if present, causing the shard to fail.
    • markAsStale

      public boolean markAsStale()
      Whether or not to mark the shard as stale (eg. removing from in-sync set) when failing the shard.