public class AllocationExplanation extends Object implements Streamable
AllocationExplanation
consists of a set of per node explanations.
Since AllocationExplanation.NodeExplanation
s are related to shards an AllocationExplanation
maps
a shards id to a set of AllocationExplanation.NodeExplanation
s.Modifier and Type | Class and Description |
---|---|
static class |
AllocationExplanation.NodeExplanation
Instances of this class keep messages and informations about nodes of an allocation
|
Modifier and Type | Field and Description |
---|---|
static AllocationExplanation |
EMPTY |
Constructor and Description |
---|
AllocationExplanation() |
Modifier and Type | Method and Description |
---|---|
AllocationExplanation |
add(ShardId shardId,
AllocationExplanation.NodeExplanation nodeExplanation)
Create and add a node explanation to this explanation referencing a shard
|
Map<ShardId,List<AllocationExplanation.NodeExplanation>> |
explanations()
List of explanations involved by this AllocationExplanation
|
static AllocationExplanation |
readAllocationExplanation(StreamInput in)
Read an
AllocationExplanation from an StreamInput |
void |
readFrom(StreamInput in) |
void |
writeTo(StreamOutput out) |
public static final AllocationExplanation EMPTY
public AllocationExplanation add(ShardId shardId, AllocationExplanation.NodeExplanation nodeExplanation)
shardId
- id the of the referenced shardnodeExplanation
- Explanation itselfpublic Map<ShardId,List<AllocationExplanation.NodeExplanation>> explanations()
public static AllocationExplanation readAllocationExplanation(StreamInput in) throws IOException
AllocationExplanation
from an StreamInput
in
- StreamInput
to read fromAllocationExplanation
read from the streamIOException
- if something bad happened while readingpublic void readFrom(StreamInput in) throws IOException
readFrom
in interface Streamable
IOException
public void writeTo(StreamOutput out) throws IOException
writeTo
in interface Streamable
IOException
Copyright © 2009–2017. All rights reserved.