stoptransform

package
v8.13.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 11, 2024 License: Apache-2.0 Imports: 12 Imported by: 3

Documentation

Overview

Stops one or more transforms.

Index

Constants

This section is empty.

Variables

View Source
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 NewStopTransform

type NewStopTransform func(transformid string) *StopTransform

NewStopTransform type alias for index.

func NewStopTransformFunc

func NewStopTransformFunc(tp elastictransport.Interface) NewStopTransform

NewStopTransformFunc returns a new instance of StopTransform with the provided transport. Used in the index of the library this allows to retrieve every apis in once place.

type Response added in v8.7.0

type Response struct {

	// Acknowledged For a successful response, this value is always true. On failure, an
	// exception is returned instead.
	Acknowledged bool `json:"acknowledged"`
}

Response holds the response body struct for the package stoptransform

https://github.com/elastic/elasticsearch-specification/blob/5bf86339cd4bda77d07f6eaa6789b72f9c0279b1/specification/transform/stop_transform/StopTransformResponse.ts#L22-L24

func NewResponse added in v8.7.0

func NewResponse() *Response

NewResponse returns a Response

type StopTransform

type StopTransform struct {
	// contains filtered or unexported fields
}

func (*StopTransform) AllowNoMatch

func (r *StopTransform) AllowNoMatch(allownomatch bool) *StopTransform

AllowNoMatch Specifies what to do when the request: contains wildcard expressions and there are no transforms that match; contains the `_all` string or no identifiers and there are no matches; contains wildcard expressions and there are only partial matches.

If it is true, the API returns a successful acknowledgement message when there are no matches. When there are only partial matches, the API stops the appropriate transforms.

If it is false, the request returns a 404 status code when there are no matches or only partial matches. API name: allow_no_match

func (StopTransform) Do

func (r StopTransform) Do(providedCtx context.Context) (*Response, error)

Do runs the request through the transport, handle the response and returns a stoptransform.Response

func (*StopTransform) Force

func (r *StopTransform) Force(force bool) *StopTransform

Force If it is true, the API forcefully stops the transforms. API name: force

func (*StopTransform) Header

func (r *StopTransform) Header(key, value string) *StopTransform

Header set a key, value pair in the StopTransform headers map.

func (*StopTransform) HttpRequest

func (r *StopTransform) HttpRequest(ctx context.Context) (*http.Request, error)

HttpRequest returns the http.Request object built from the given parameters.

func (StopTransform) IsSuccess

func (r StopTransform) IsSuccess(providedCtx context.Context) (bool, error)

IsSuccess allows to run a query with a context and retrieve the result as a boolean. This only exists for endpoints without a request payload and allows for quick control flow.

func (StopTransform) Perform added in v8.7.0

func (r StopTransform) Perform(providedCtx context.Context) (*http.Response, error)

Perform runs the http.Request through the provided transport and returns an http.Response.

func (*StopTransform) Timeout

func (r *StopTransform) Timeout(duration string) *StopTransform

Timeout Period to wait for a response when `wait_for_completion` is `true`. If no response is received before the timeout expires, the request returns a timeout exception. However, the request continues processing and eventually moves the transform to a STOPPED state. API name: timeout

func (*StopTransform) WaitForCheckpoint

func (r *StopTransform) WaitForCheckpoint(waitforcheckpoint bool) *StopTransform

WaitForCheckpoint If it is true, the transform does not completely stop until the current checkpoint is completed. If it is false, the transform stops as soon as possible. API name: wait_for_checkpoint

func (*StopTransform) WaitForCompletion

func (r *StopTransform) WaitForCompletion(waitforcompletion bool) *StopTransform

WaitForCompletion If it is true, the API blocks until the indexer state completely stops. If it is false, the API returns immediately and the indexer is stopped asynchronously in the background. API name: wait_for_completion

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL