Class IndexLifecycleClient


  • public class IndexLifecycleClient
    extends java.lang.Object
    • Method Detail

      • getLifecyclePolicy

        public GetLifecyclePolicyResponse getLifecyclePolicy​(GetLifecyclePolicyRequest request,
                                                             RequestOptions options)
                                                      throws java.io.IOException
        Retrieve one or more lifecycle policy definition. See the docs for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        Returns:
        the response
        Throws:
        java.io.IOException - in case there is a problem sending the request or parsing back the response
      • putLifecyclePolicy

        public AcknowledgedResponse putLifecyclePolicy​(PutLifecyclePolicyRequest request,
                                                       RequestOptions options)
                                                throws java.io.IOException
        Create or modify a lifecycle definition. See the docs for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        Returns:
        the response
        Throws:
        java.io.IOException - in case there is a problem sending the request or parsing back the response
      • deleteLifecyclePolicy

        public AcknowledgedResponse deleteLifecyclePolicy​(DeleteLifecyclePolicyRequest request,
                                                          RequestOptions options)
                                                   throws java.io.IOException
        Delete a lifecycle definition See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-delete-lifecycle-policy.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        Returns:
        the response
        Throws:
        java.io.IOException - in case there is a problem sending the request or parsing back the response
      • deleteLifecyclePolicyAsync

        public void deleteLifecyclePolicyAsync​(DeleteLifecyclePolicyRequest request,
                                               RequestOptions options,
                                               ActionListener<AcknowledgedResponse> listener)
        Asynchronously delete a lifecycle definition See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-delete-lifecycle-policy.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        listener - the listener to be notified upon request completion
      • removeIndexLifecyclePolicy

        public RemoveIndexLifecyclePolicyResponse removeIndexLifecyclePolicy​(RemoveIndexLifecyclePolicyRequest request,
                                                                             RequestOptions options)
                                                                      throws java.io.IOException
        Remove the index lifecycle policy for an index See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-remove-lifecycle-policy-from-index.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        Returns:
        the response
        Throws:
        java.io.IOException - in case there is a problem sending the request or parsing back the response
      • removeIndexLifecyclePolicyAsync

        public void removeIndexLifecyclePolicyAsync​(RemoveIndexLifecyclePolicyRequest request,
                                                    RequestOptions options,
                                                    ActionListener<RemoveIndexLifecyclePolicyResponse> listener)
        Asynchronously remove the index lifecycle policy for an index See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-remove-lifecycle-policy-from-index.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        listener - the listener to be notified upon request completion
      • startILM

        public AcknowledgedResponse startILM​(StartILMRequest request,
                                             RequestOptions options)
                                      throws java.io.IOException
        Start the Index Lifecycle Management feature. See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-start-ilm.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        Returns:
        the response
        Throws:
        java.io.IOException - in case there is a problem sending the request or parsing back the response
      • startILMAsync

        public void startILMAsync​(StartILMRequest request,
                                  RequestOptions options,
                                  ActionListener<AcknowledgedResponse> listener)
        Asynchronously start the Index Lifecycle Management feature. See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-start-ilm.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        listener - the listener to be notified upon request completion
      • stopILM

        public AcknowledgedResponse stopILM​(StopILMRequest request,
                                            RequestOptions options)
                                     throws java.io.IOException
        Stop the Index Lifecycle Management feature. See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-stop-ilm.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        Returns:
        the response
        Throws:
        java.io.IOException - in case there is a problem sending the request or parsing back the response
      • stopILMAsync

        public void stopILMAsync​(StopILMRequest request,
                                 RequestOptions options,
                                 ActionListener<AcknowledgedResponse> listener)
        Asynchronously stop the Index Lifecycle Management feature. See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-stop-ilm.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        listener - the listener to be notified upon request completion
      • lifecycleManagementStatus

        public LifecycleManagementStatusResponse lifecycleManagementStatus​(LifecycleManagementStatusRequest request,
                                                                           RequestOptions options)
                                                                    throws java.io.IOException
        Get the status of index lifecycle management See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-status.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        Throws:
        java.io.IOException
      • lifecycleManagementStatusAsync

        public void lifecycleManagementStatusAsync​(LifecycleManagementStatusRequest request,
                                                   RequestOptions options,
                                                   ActionListener<LifecycleManagementStatusResponse> listener)
        Asynchronously get the status of index lifecycle management See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-status.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        listener - the listener to be notified upon request completion
      • explainLifecycle

        public ExplainLifecycleResponse explainLifecycle​(ExplainLifecycleRequest request,
                                                         RequestOptions options)
                                                  throws java.io.IOException
        Explain the lifecycle state for an index See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-explain-lifecycle.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        Returns:
        the response
        Throws:
        java.io.IOException - in case there is a problem sending the request or parsing back the response
      • explainLifecycleAsync

        public void explainLifecycleAsync​(ExplainLifecycleRequest request,
                                          RequestOptions options,
                                          ActionListener<ExplainLifecycleResponse> listener)
        Asynchronously explain the lifecycle state for an index See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-explain-lifecycle.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        listener - the listener to be notified upon request completion
      • retryLifecyclePolicy

        public AcknowledgedResponse retryLifecyclePolicy​(RetryLifecyclePolicyRequest request,
                                                         RequestOptions options)
                                                  throws java.io.IOException
        Retry lifecycle step for given indices See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-retry-lifecycle-policy.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        Returns:
        the response
        Throws:
        java.io.IOException - in case there is a problem sending the request or parsing back the response
      • retryLifecyclePolicyAsync

        public void retryLifecyclePolicyAsync​(RetryLifecyclePolicyRequest request,
                                              RequestOptions options,
                                              ActionListener<AcknowledgedResponse> listener)
        Asynchronously retry the lifecycle step for given indices See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-ilm-retry-lifecycle-policy.html
         
        for more.
        Parameters:
        request - the request
        options - the request options (e.g. headers), use RequestOptions.DEFAULT if nothing needs to be customized
        listener - the listener to be notified upon request completion