Module org.elasticsearch.xcore
Package org.elasticsearch.xpack.core.ilm
Class SearchableSnapshotAction
java.lang.Object
org.elasticsearch.xpack.core.ilm.SearchableSnapshotAction
- All Implemented Interfaces:
NamedWriteable,Writeable,org.elasticsearch.xcontent.ToXContent,org.elasticsearch.xcontent.ToXContentObject,LifecycleAction
A
LifecycleAction that will convert the index into a searchable snapshot, by taking a snapshot of the index, creating a
searchable snapshot and the corresponding "searchable snapshot index", deleting the original index and swapping its aliases to the
newly created searchable snapshot backed index.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.xcontent.ToXContent
org.elasticsearch.xcontent.ToXContent.DelegatingMapParams, org.elasticsearch.xcontent.ToXContent.MapParams, org.elasticsearch.xcontent.ToXContent.ParamsNested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V> -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final org.elasticsearch.xcontent.ParseFieldstatic final Stringstatic final Stringstatic final Stringstatic final org.elasticsearch.xcontent.ParseFieldstatic final org.elasticsearch.xcontent.ParseFieldstatic final org.elasticsearch.xcontent.ParseFieldFields inherited from interface org.elasticsearch.xcontent.ToXContent
EMPTY, EMPTY_PARAMS -
Constructor Summary
ConstructorsConstructorDescriptionSearchableSnapshotAction(String snapshotRepository) SearchableSnapshotAction(String snapshotRepository, boolean forceMergeIndex) SearchableSnapshotAction(String snapshotRepository, boolean forceMergeIndex, Integer totalShardsPerNode, org.elasticsearch.core.TimeValue replicateFor) -
Method Summary
Modifier and TypeMethodDescriptionbooleanorg.elasticsearch.core.TimeValueinthashCode()booleanstatic SearchableSnapshotActionparse(org.elasticsearch.xcontent.XContentParser parser) toSteps(Client client, String phase, Step.StepKey nextStepKey) converts theLifecycleAction's execution plan into a series ofSteps that reference each other to preserve order of operations.toSteps(Client client, String phase, Step.StepKey nextStepKey, XPackLicenseState licenseState) converts theLifecycleAction's execution plan into a series ofSteps that reference each other to preserve order of operations.org.elasticsearch.xcontent.XContentBuildertoXContent(org.elasticsearch.xcontent.XContentBuilder builder, org.elasticsearch.xcontent.ToXContent.Params params) voidwriteTo(StreamOutput out) Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.elasticsearch.xcontent.ToXContentObject
isFragment
-
Field Details
-
NAME
- See Also:
-
SNAPSHOT_REPOSITORY
public static final org.elasticsearch.xcontent.ParseField SNAPSHOT_REPOSITORY -
FORCE_MERGE_INDEX
public static final org.elasticsearch.xcontent.ParseField FORCE_MERGE_INDEX -
TOTAL_SHARDS_PER_NODE
public static final org.elasticsearch.xcontent.ParseField TOTAL_SHARDS_PER_NODE -
REPLICATE_FOR
public static final org.elasticsearch.xcontent.ParseField REPLICATE_FOR -
CONDITIONAL_DATASTREAM_CHECK_KEY
- See Also:
-
CONDITIONAL_SKIP_ACTION_STEP
- See Also:
-
CONDITIONAL_SKIP_GENERATE_AND_CLEAN
- See Also:
-
FULL_RESTORED_INDEX_PREFIX
- See Also:
-
PARTIAL_RESTORED_INDEX_PREFIX
- See Also:
-
-
Constructor Details
-
SearchableSnapshotAction
-
SearchableSnapshotAction
-
SearchableSnapshotAction
-
SearchableSnapshotAction
- Throws:
IOException
-
-
Method Details
-
parse
-
getSnapshotRepository
-
getTotalShardsPerNode
-
getReplicateFor
@Nullable public org.elasticsearch.core.TimeValue getReplicateFor() -
toSteps
Description copied from interface:LifecycleActionconverts theLifecycleAction's execution plan into a series ofSteps that reference each other to preserve order of operations.- Specified by:
toStepsin interfaceLifecycleAction- Parameters:
client- the client that will be used byAsyncActionStepandAsyncWaitStepstepsphase- the name of the phase this action is being executed withinnextStepKey- the next step to execute after this action's steps. If null, then there are no further steps to run. It is the responsibility of eachLifecycleActionto implement this correctly and not forget to link to this final step so that the policy can continue.- Returns:
- an ordered list of steps that represent the execution plan of the action
-
toSteps
public List<Step> toSteps(Client client, String phase, Step.StepKey nextStepKey, XPackLicenseState licenseState) Description copied from interface:LifecycleActionconverts theLifecycleAction's execution plan into a series ofSteps that reference each other to preserve order of operations. This overload allows access to license state.- Specified by:
toStepsin interfaceLifecycleAction- Parameters:
client- the client that will be used byAsyncActionStepandAsyncWaitStepstepsphase- the name of the phase this action is being executed withinnextStepKey- the next step to execute after this action's steps. If null, then there are no further steps to run. It is the responsibility of eachLifecycleActionto implement this correctly and not forget to link to this final step so that the policy can continue.licenseState- the license state to use for actions that need license checks.- Returns:
- an ordered list of steps that represent the execution plan of the action
-
isSafeAction
public boolean isSafeAction()- Specified by:
isSafeActionin interfaceLifecycleAction- Returns:
- true if this action is considered safe. An action is not safe if it will produce unwanted side effects or will get stuck when the action configuration is changed while an index is in this action
-
getWriteableName
- Specified by:
getWriteableNamein interfaceNamedWriteable
-
writeTo
- Specified by:
writeToin interfaceWriteable- Throws:
IOException
-
toXContent
public org.elasticsearch.xcontent.XContentBuilder toXContent(org.elasticsearch.xcontent.XContentBuilder builder, org.elasticsearch.xcontent.ToXContent.Params params) throws IOException - Specified by:
toXContentin interfaceorg.elasticsearch.xcontent.ToXContent- Throws:
IOException
-
equals
-
hashCode
public int hashCode()
-