Class RecoverySource
- java.lang.Object
-
- org.elasticsearch.cluster.routing.RecoverySource
-
- All Implemented Interfaces:
Writeable
,ToXContent
,ToXContentObject
- Direct Known Subclasses:
RecoverySource.EmptyStoreRecoverySource
,RecoverySource.ExistingStoreRecoverySource
,RecoverySource.LocalShardsRecoverySource
,RecoverySource.PeerRecoverySource
,RecoverySource.SnapshotRecoverySource
public abstract class RecoverySource extends java.lang.Object implements Writeable, ToXContentObject
Represents the recovery source of a shard. Available recovery types are: -RecoverySource.EmptyStoreRecoverySource
recovery from an empty store -RecoverySource.ExistingStoreRecoverySource
recovery from an existing store -RecoverySource.PeerRecoverySource
recovery from a primary on another node -RecoverySource.SnapshotRecoverySource
recovery from a snapshot -RecoverySource.LocalShardsRecoverySource
recovery from other shards of another index on the same node
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
RecoverySource.EmptyStoreRecoverySource
Recovery from a fresh copystatic class
RecoverySource.ExistingStoreRecoverySource
Recovery from an existing on-disk storestatic class
RecoverySource.LocalShardsRecoverySource
recovery from other shards on same node (shrink index action)static class
RecoverySource.PeerRecoverySource
peer recovery from a primary shardstatic class
RecoverySource.SnapshotRecoverySource
recovery from a snapshotstatic class
RecoverySource.Type
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
-
Field Summary
-
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
-
-
Constructor Summary
Constructors Constructor Description RecoverySource()
-
Method Summary
Modifier and Type Method Description void
addAdditionalFields(XContentBuilder builder, ToXContent.Params params)
to be overridden by subclassesboolean
equals(java.lang.Object o)
boolean
expectEmptyRetentionLeases()
abstract RecoverySource.Type
getType()
int
hashCode()
static RecoverySource
readFrom(StreamInput in)
boolean
shouldBootstrapNewHistoryUUID()
XContentBuilder
toXContent(XContentBuilder builder, ToXContent.Params params)
protected void
writeAdditionalFields(StreamOutput out)
to be overridden by subclassesvoid
writeTo(StreamOutput out)
Write this into the StreamOutput.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentObject
isFragment
-
-
-
-
Method Detail
-
toXContent
public final XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
- Specified by:
toXContent
in interfaceToXContent
- Throws:
java.io.IOException
-
addAdditionalFields
public void addAdditionalFields(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
to be overridden by subclasses- Throws:
java.io.IOException
-
readFrom
public static RecoverySource readFrom(StreamInput in) throws java.io.IOException
- Throws:
java.io.IOException
-
writeTo
public final void writeTo(StreamOutput out) throws java.io.IOException
Description copied from interface:Writeable
Write this into the StreamOutput.
-
writeAdditionalFields
protected void writeAdditionalFields(StreamOutput out) throws java.io.IOException
to be overridden by subclasses- Throws:
java.io.IOException
-
getType
public abstract RecoverySource.Type getType()
-
shouldBootstrapNewHistoryUUID
public boolean shouldBootstrapNewHistoryUUID()
-
expectEmptyRetentionLeases
public boolean expectEmptyRetentionLeases()
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-