Package org.elasticsearch.action
Class ShardOperationFailedException
- java.lang.Object
-
- org.elasticsearch.action.ShardOperationFailedException
-
- All Implemented Interfaces:
Streamable
,ToXContent
- Direct Known Subclasses:
DefaultShardOperationFailedException
,ReplicationResponse.ShardInfo.Failure
,ShardSearchFailure
,SnapshotShardFailure
public abstract class ShardOperationFailedException extends java.lang.Object implements Streamable, ToXContent
An exception indicating that a failure occurred performing an operation on the shard.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.Throwable
cause
protected java.lang.String
index
protected java.lang.String
reason
protected int
shardId
protected RestStatus
status
-
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
ShardOperationFailedException()
protected
ShardOperationFailedException(java.lang.String index, int shardId, java.lang.String reason, RestStatus status, java.lang.Throwable cause)
-
Method Summary
Modifier and Type Method Description java.lang.Throwable
getCause()
The cause of this failurejava.lang.String
index()
The index the operation failed on.java.lang.String
reason()
The reason of the failure.int
shardId()
The index the operation failed on.RestStatus
status()
The status of the failure.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.elasticsearch.common.io.stream.Streamable
readFrom, writeTo
-
Methods inherited from interface org.elasticsearch.common.xcontent.ToXContent
isFragment, toXContent
-
-
-
-
Field Detail
-
index
protected java.lang.String index
-
shardId
protected int shardId
-
reason
protected java.lang.String reason
-
status
protected RestStatus status
-
cause
protected java.lang.Throwable cause
-
-
Constructor Detail
-
ShardOperationFailedException
protected ShardOperationFailedException()
-
ShardOperationFailedException
protected ShardOperationFailedException(@Nullable java.lang.String index, int shardId, java.lang.String reason, RestStatus status, java.lang.Throwable cause)
-
-
Method Detail
-
index
@Nullable public final java.lang.String index()
The index the operation failed on. Might returnnull
if it can't be derived.
-
shardId
public final int shardId()
The index the operation failed on. Might return-1
if it can't be derived.
-
reason
public final java.lang.String reason()
The reason of the failure.
-
status
public final RestStatus status()
The status of the failure.
-
getCause
public final java.lang.Throwable getCause()
The cause of this failure
-
-