|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.elasticsearch.cluster.routing.ImmutableShardRouting
public class ImmutableShardRouting
| Field Summary | |
|---|---|
protected java.lang.String |
currentNodeId
|
protected java.lang.String |
index
|
protected boolean |
primary
|
protected java.lang.String |
relocatingNodeId
|
protected int |
shardId
|
protected ShardRoutingState |
state
|
| Constructor Summary | |
|---|---|
ImmutableShardRouting()
|
|
ImmutableShardRouting(ShardRouting copy)
|
|
ImmutableShardRouting(java.lang.String index,
int shardId,
java.lang.String currentNodeId,
boolean primary,
ShardRoutingState state)
|
|
ImmutableShardRouting(java.lang.String index,
int shardId,
java.lang.String currentNodeId,
java.lang.String relocatingNodeId,
boolean primary,
ShardRoutingState state)
|
|
| Method Summary | |
|---|---|
boolean |
active()
Relocating or started. |
boolean |
assignedToNode()
The shard is assigned to a node. |
java.lang.String |
currentNodeId()
The current node id the shard is allocated to. |
boolean |
equals(java.lang.Object o)
|
int |
getId()
The shard id. |
java.lang.String |
getIndex()
The index name. |
int |
hashCode()
|
int |
id()
The shard id. |
java.lang.String |
index()
The index name. |
boolean |
initializing()
The shard is initializing (usually recovering either from peer shard or from gateway). |
boolean |
primary()
Is this a primary shard. |
void |
readFrom(StreamInput in)
|
void |
readFrom(StreamInput in,
java.lang.String index,
int shardId)
|
void |
readFromThin(StreamInput in)
|
static ImmutableShardRouting |
readShardRoutingEntry(StreamInput in)
|
static ImmutableShardRouting |
readShardRoutingEntry(StreamInput in,
java.lang.String index,
int shardId)
|
boolean |
relocating()
The shard is in relocating mode. |
java.lang.String |
relocatingNodeId()
The relocating node id the shard is either relocating to or relocating from. |
ShardId |
shardId()
The shard id. |
ShardsIterator |
shardsIt()
A shard iterator with just this shard in it. |
java.lang.String |
shortSummary()
A short description of the shard. |
boolean |
started()
The shard is in started mode. |
ShardRoutingState |
state()
The shard state. |
java.lang.String |
toString()
|
boolean |
unassigned()
The shard is unassigned (not allocated to any node). |
void |
writeTo(StreamOutput out)
|
void |
writeToThin(StreamOutput out)
Does not write index name and shard id |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected java.lang.String index
protected int shardId
protected java.lang.String currentNodeId
protected java.lang.String relocatingNodeId
protected boolean primary
protected ShardRoutingState state
| Constructor Detail |
|---|
public ImmutableShardRouting()
public ImmutableShardRouting(ShardRouting copy)
public ImmutableShardRouting(java.lang.String index,
int shardId,
java.lang.String currentNodeId,
boolean primary,
ShardRoutingState state)
public ImmutableShardRouting(java.lang.String index,
int shardId,
java.lang.String currentNodeId,
java.lang.String relocatingNodeId,
boolean primary,
ShardRoutingState state)
| Method Detail |
|---|
public java.lang.String index()
ShardRouting
index in interface ShardRoutingpublic java.lang.String getIndex()
ShardRouting
getIndex in interface ShardRoutingpublic int id()
ShardRouting
id in interface ShardRoutingpublic int getId()
ShardRouting
getId in interface ShardRoutingpublic boolean unassigned()
ShardRouting
unassigned in interface ShardRoutingpublic boolean initializing()
ShardRouting
initializing in interface ShardRoutingpublic boolean active()
ShardRouting
active in interface ShardRoutingpublic boolean started()
ShardRouting
started in interface ShardRoutingpublic boolean relocating()
ShardRouting
relocating in interface ShardRoutingpublic boolean assignedToNode()
ShardRouting
assignedToNode in interface ShardRoutingpublic java.lang.String currentNodeId()
ShardRouting
currentNodeId in interface ShardRoutingpublic java.lang.String relocatingNodeId()
ShardRouting
relocatingNodeId in interface ShardRoutingpublic boolean primary()
ShardRouting
primary in interface ShardRoutingpublic ShardRoutingState state()
ShardRouting
state in interface ShardRoutingpublic ShardId shardId()
ShardRouting
shardId in interface ShardRoutingpublic ShardsIterator shardsIt()
ShardRouting
shardsIt in interface ShardRouting
public static ImmutableShardRouting readShardRoutingEntry(StreamInput in)
throws java.io.IOException
java.io.IOException
public static ImmutableShardRouting readShardRoutingEntry(StreamInput in,
java.lang.String index,
int shardId)
throws java.io.IOException
java.io.IOException
public void readFrom(StreamInput in,
java.lang.String index,
int shardId)
throws java.io.IOException
java.io.IOException
public void readFromThin(StreamInput in)
throws java.io.IOException
readFromThin in interface ShardRoutingjava.io.IOException
public void readFrom(StreamInput in)
throws java.io.IOException
readFrom in interface Streamablejava.io.IOException
public void writeToThin(StreamOutput out)
throws java.io.IOException
writeToThin in interface ShardRoutingjava.io.IOException
public void writeTo(StreamOutput out)
throws java.io.IOException
writeTo in interface Streamablejava.io.IOExceptionpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.String shortSummary()
ShardRouting
shortSummary in interface ShardRouting
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||