api

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2021 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MakeGenericRequest

func MakeGenericRequest(esClient *elastic7.Client, cmdOpts *opts.CommandOptions) error

Types

type GenericRequest

type GenericRequest struct {
	Request *http.Request

	Body io.Reader

	Name       []string
	Format     string
	H          []string
	Help       *bool
	Local      *bool
	S          []string
	V          *bool
	Pretty     bool
	Human      bool
	ErrorTrace bool
	FilterPath []string

	Header http.Header
	// contains filtered or unexported fields
}

Wrapper around http.Request with esapi fields

func (GenericRequest) Do

func (r GenericRequest) Do(ctx context.Context, transport esapi.Transport) (*esapi.Response, error)

Inspired by https://github.com/elastic/go-elasticsearch/blob/52d1cf7160ac9b92b81ac6c82acec3f20351d8e7/esapi/api.bulk.go#L64 This is now an esRequest than can be used by esutil Has a similar form to most *Request structs under esapi

Jump to

Keyboard shortcuts

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