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 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
      • startILM

        public AcknowledgedResponse startILM​(StartILMRequest request,
                                             RequestOptions options)
                                      throws java.io.IOException
        Start the Index Lifecycle Management feature. 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
      • stopILM

        public AcknowledgedResponse stopILM​(StopILMRequest request,
                                            RequestOptions options)
                                     throws java.io.IOException
        Stop the Index Lifecycle Management feature. 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
      • explainLifecycle

        public ExplainLifecycleResponse explainLifecycle​(ExplainLifecycleRequest request,
                                                         RequestOptions options)
                                                  throws java.io.IOException
        Explain the lifecycle state for an index 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
      • retryLifecyclePolicy

        public AcknowledgedResponse retryLifecyclePolicy​(RetryLifecyclePolicyRequest request,
                                                         RequestOptions options)
                                                  throws java.io.IOException
        Retry lifecycle step for given indices 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
      • getSnapshotLifecyclePolicy

        public GetSnapshotLifecyclePolicyResponse getSnapshotLifecyclePolicy​(GetSnapshotLifecyclePolicyRequest request,
                                                                             RequestOptions options)
                                                                      throws java.io.IOException
        Retrieve one or more snapshot lifecycle policy definitions. See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-slm-get-snapshot-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
      • getSnapshotLifecyclePolicyAsync

        public void getSnapshotLifecyclePolicyAsync​(GetSnapshotLifecyclePolicyRequest request,
                                                    RequestOptions options,
                                                    ActionListener<GetSnapshotLifecyclePolicyResponse> listener)
        Asynchronously retrieve one or more snapshot lifecycle policy definition. See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-slm-get-snapshot-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
      • putSnapshotLifecyclePolicy

        public AcknowledgedResponse putSnapshotLifecyclePolicy​(PutSnapshotLifecyclePolicyRequest request,
                                                               RequestOptions options)
                                                        throws java.io.IOException
        Create or modify a snapshot lifecycle definition. See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-slm-put-snapshot-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
      • putSnapshotLifecyclePolicyAsync

        public void putSnapshotLifecyclePolicyAsync​(PutSnapshotLifecyclePolicyRequest request,
                                                    RequestOptions options,
                                                    ActionListener<AcknowledgedResponse> listener)
        Asynchronously create or modify a snapshot lifecycle definition. See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-slm-put-snapshot-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
      • deleteSnapshotLifecyclePolicy

        public AcknowledgedResponse deleteSnapshotLifecyclePolicy​(DeleteSnapshotLifecyclePolicyRequest request,
                                                                  RequestOptions options)
                                                           throws java.io.IOException
        Delete a snapshot lifecycle definition See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-slm-delete-snapshot-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
      • deleteSnapshotLifecyclePolicyAsync

        public void deleteSnapshotLifecyclePolicyAsync​(DeleteSnapshotLifecyclePolicyRequest request,
                                                       RequestOptions options,
                                                       ActionListener<AcknowledgedResponse> listener)
        Asynchronously delete a snapshot lifecycle definition See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-slm-delete-snapshot-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
      • executeSnapshotLifecyclePolicy

        public ExecuteSnapshotLifecyclePolicyResponse executeSnapshotLifecyclePolicy​(ExecuteSnapshotLifecyclePolicyRequest request,
                                                                                     RequestOptions options)
                                                                              throws java.io.IOException
        Execute a snapshot lifecycle definition See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-slm-execute-snapshot-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
      • executeSnapshotLifecyclePolicyAsync

        public void executeSnapshotLifecyclePolicyAsync​(ExecuteSnapshotLifecyclePolicyRequest request,
                                                        RequestOptions options,
                                                        ActionListener<ExecuteSnapshotLifecyclePolicyResponse> listener)
        Asynchronously execute a snapshot lifecycle definition See
          https://www.elastic.co/guide/en/elasticsearch/client/java-rest/current/
          java-rest-high-ilm-slm-execute-snapshot-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