Documentation ¶
Overview ¶
Immediately creates a snapshot according to the lifecycle policy, without waiting for the scheduled time.
Index ¶
- Variables
- type ExecuteLifecycle
- func (r ExecuteLifecycle) Do(providedCtx context.Context) (*Response, error)
- func (r *ExecuteLifecycle) Header(key, value string) *ExecuteLifecycle
- func (r *ExecuteLifecycle) HttpRequest(ctx context.Context) (*http.Request, error)
- func (r ExecuteLifecycle) IsSuccess(providedCtx context.Context) (bool, error)
- func (r ExecuteLifecycle) Perform(providedCtx context.Context) (*http.Response, error)
- type NewExecuteLifecycle
- type Response
Constants ¶
This section is empty.
Variables ¶
var ErrBuildPath = errors.New("cannot build path, check for missing path parameters")
ErrBuildPath is returned in case of missing parameters within the build of the request.
Functions ¶
This section is empty.
Types ¶
type ExecuteLifecycle ¶
type ExecuteLifecycle struct {
// contains filtered or unexported fields
}
func New ¶
func New(tp elastictransport.Interface) *ExecuteLifecycle
Immediately creates a snapshot according to the lifecycle policy, without waiting for the scheduled time.
https://www.elastic.co/guide/en/elasticsearch/reference/current/slm-api-execute-lifecycle.html
func (ExecuteLifecycle) Do ¶
func (r ExecuteLifecycle) Do(providedCtx context.Context) (*Response, error)
Do runs the request through the transport, handle the response and returns a executelifecycle.Response
func (*ExecuteLifecycle) Header ¶
func (r *ExecuteLifecycle) Header(key, value string) *ExecuteLifecycle
Header set a key, value pair in the ExecuteLifecycle headers map.
func (*ExecuteLifecycle) HttpRequest ¶
HttpRequest returns the http.Request object built from the given parameters.
type NewExecuteLifecycle ¶
type NewExecuteLifecycle func(policyid string) *ExecuteLifecycle
NewExecuteLifecycle type alias for index.
func NewExecuteLifecycleFunc ¶
func NewExecuteLifecycleFunc(tp elastictransport.Interface) NewExecuteLifecycle
NewExecuteLifecycleFunc returns a new instance of ExecuteLifecycle with the provided transport. Used in the index of the library this allows to retrieve every apis in once place.