Class IndicesShardStoresResponse.StoreStatus
- java.lang.Object
-
- org.elasticsearch.action.admin.indices.shards.IndicesShardStoresResponse.StoreStatus
-
- All Implemented Interfaces:
java.lang.Comparable<IndicesShardStoresResponse.StoreStatus>
,Streamable
,ToXContent
,ToXContentFragment
- Enclosing class:
- IndicesShardStoresResponse
public static class IndicesShardStoresResponse.StoreStatus extends java.lang.Object implements Streamable, ToXContentFragment, java.lang.Comparable<IndicesShardStoresResponse.StoreStatus>
Shard store information from a node
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
IndicesShardStoresResponse.StoreStatus.AllocationStatus
The status of the shard store with respect to the cluster-
Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
-
-
Field Summary
-
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
-
-
Constructor Summary
Constructors Constructor Description StoreStatus(DiscoveryNode node, java.lang.String allocationId, IndicesShardStoresResponse.StoreStatus.AllocationStatus allocationStatus, java.lang.Exception storeException)
-
Method Summary
Modifier and Type Method Description int
compareTo(IndicesShardStoresResponse.StoreStatus other)
java.lang.String
getAllocationId()
AllocationStatus id of the store, used to select the store that will be used as a primary.IndicesShardStoresResponse.StoreStatus.AllocationStatus
getAllocationStatus()
The allocationStatus status of the store.DiscoveryNode
getNode()
Node the store belongs tojava.lang.Exception
getStoreException()
Exception while trying to open the shard index or from when the shard failedvoid
readFrom(StreamInput in)
Set this object's fields from a StreamInput.static IndicesShardStoresResponse.StoreStatus
readStoreStatus(StreamInput in)
XContentBuilder
toXContent(XContentBuilder builder, ToXContent.Params params)
void
writeTo(StreamOutput out)
Write this object's fields to a StreamOutput.-
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.xcontent.ToXContentFragment
isFragment
-
-
-
-
Constructor Detail
-
StoreStatus
public StoreStatus(DiscoveryNode node, java.lang.String allocationId, IndicesShardStoresResponse.StoreStatus.AllocationStatus allocationStatus, java.lang.Exception storeException)
-
-
Method Detail
-
getNode
public DiscoveryNode getNode()
Node the store belongs to
-
getAllocationId
public java.lang.String getAllocationId()
AllocationStatus id of the store, used to select the store that will be used as a primary.
-
getStoreException
public java.lang.Exception getStoreException()
Exception while trying to open the shard index or from when the shard failed
-
getAllocationStatus
public IndicesShardStoresResponse.StoreStatus.AllocationStatus getAllocationStatus()
The allocationStatus status of the store.IndicesShardStoresResponse.StoreStatus.AllocationStatus.PRIMARY
indicates a primary shard copyIndicesShardStoresResponse.StoreStatus.AllocationStatus.REPLICA
indicates a replica shard copyIndicesShardStoresResponse.StoreStatus.AllocationStatus.UNUSED
indicates an unused shard copy
-
readStoreStatus
public static IndicesShardStoresResponse.StoreStatus readStoreStatus(StreamInput in) throws java.io.IOException
- Throws:
java.io.IOException
-
readFrom
public void readFrom(StreamInput in) throws java.io.IOException
Description copied from interface:Streamable
Set this object's fields from a StreamInput.- Specified by:
readFrom
in interfaceStreamable
- Throws:
java.io.IOException
-
writeTo
public void writeTo(StreamOutput out) throws java.io.IOException
Description copied from interface:Streamable
Write this object's fields to a StreamOutput.- Specified by:
writeTo
in interfaceStreamable
- Throws:
java.io.IOException
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
- Specified by:
toXContent
in interfaceToXContent
- Throws:
java.io.IOException
-
compareTo
public int compareTo(IndicesShardStoresResponse.StoreStatus other)
- Specified by:
compareTo
in interfacejava.lang.Comparable<IndicesShardStoresResponse.StoreStatus>
-
-