Class DownsampleAction

java.lang.Object
org.elasticsearch.xpack.core.ilm.DownsampleAction
All Implemented Interfaces:
NamedWriteable, Writeable, org.elasticsearch.xcontent.ToXContent, org.elasticsearch.xcontent.ToXContentObject, LifecycleAction

public class DownsampleAction extends Object implements LifecycleAction
A LifecycleAction which calls DownsampleAction on an index
  • Field Details

    • ILM_FORCE_MERGE_IN_DOWNSAMPLING

      public static final TransportVersion ILM_FORCE_MERGE_IN_DOWNSAMPLING
    • ADD_SAMPLE_METHOD_DOWNSAMPLE_ILM

      public static final TransportVersion ADD_SAMPLE_METHOD_DOWNSAMPLE_ILM
    • NAME

      public static final String NAME
      See Also:
    • DOWNSAMPLED_INDEX_PREFIX

      public static final String DOWNSAMPLED_INDEX_PREFIX
      See Also:
    • CONDITIONAL_TIME_SERIES_CHECK_KEY

      public static final String CONDITIONAL_TIME_SERIES_CHECK_KEY
      See Also:
    • CONDITIONAL_DATASTREAM_CHECK_KEY

      public static final String CONDITIONAL_DATASTREAM_CHECK_KEY
      See Also:
    • DEFAULT_WAIT_TIMEOUT

      public static final org.elasticsearch.core.TimeValue DEFAULT_WAIT_TIMEOUT
  • Constructor Details

  • Method Details

    • parse

      public static DownsampleAction parse(org.elasticsearch.xcontent.XContentParser parser)
    • writeTo

      public void writeTo(StreamOutput out) throws IOException
      Specified by:
      writeTo in interface Writeable
      Throws:
      IOException
    • toXContent

      public org.elasticsearch.xcontent.XContentBuilder toXContent(org.elasticsearch.xcontent.XContentBuilder builder, org.elasticsearch.xcontent.ToXContent.Params params) throws IOException
      Specified by:
      toXContent in interface org.elasticsearch.xcontent.ToXContent
      Throws:
      IOException
    • getWriteableName

      public String getWriteableName()
      Specified by:
      getWriteableName in interface NamedWriteable
    • fixedInterval

      public DateHistogramInterval fixedInterval()
    • waitTimeout

      public org.elasticsearch.core.TimeValue waitTimeout()
    • forceMergeIndex

      public Boolean forceMergeIndex()
    • samplingMethod

      @Nullable public DownsampleConfig.SamplingMethod samplingMethod()
      Returns:
      the sampling method configured in the ILM policy or null
    • samplingMethodOrDefault

      public DownsampleConfig.SamplingMethod samplingMethodOrDefault()
      Returns:
      the sampling method that will be applied when the downsample occurs.
    • isSafeAction

      public boolean isSafeAction()
      Specified by:
      isSafeAction in interface LifecycleAction
      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
    • toSteps

      public List<Step> toSteps(Client client, String phase, Step.StepKey nextStepKey)
      Description copied from interface: LifecycleAction
      converts the LifecycleAction's execution plan into a series of Steps that reference each other to preserve order of operations.
      Specified by:
      toSteps in interface LifecycleAction
      Parameters:
      client - the client that will be used by AsyncActionStep and AsyncWaitStep steps
      phase - the name of the phase this action is being executed within
      nextStepKey - 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 each LifecycleAction to 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
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object