Documentation ¶
Overview ¶
Creates a data stream
Index ¶
- Variables
- type CreateDataStream
- func (r CreateDataStream) Do(ctx context.Context) (*http.Response, error)
- func (r *CreateDataStream) Header(key, value string) *CreateDataStream
- func (r *CreateDataStream) HttpRequest(ctx context.Context) (*http.Request, error)
- func (r CreateDataStream) IsSuccess(ctx context.Context) (bool, error)
- func (r *CreateDataStream) Name(v string) *CreateDataStream
- type NewCreateDataStream
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 CreateDataStream ¶
type CreateDataStream struct {
// contains filtered or unexported fields
}
func New ¶
func New(tp elastictransport.Interface) *CreateDataStream
Creates a data stream
https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html
func (*CreateDataStream) Header ¶
func (r *CreateDataStream) Header(key, value string) *CreateDataStream
Header set a key, value pair in the CreateDataStream headers map.
func (*CreateDataStream) HttpRequest ¶
HttpRequest returns the http.Request object built from the given parameters.
func (CreateDataStream) IsSuccess ¶
func (r CreateDataStream) IsSuccess(ctx 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 (*CreateDataStream) Name ¶
func (r *CreateDataStream) Name(v string) *CreateDataStream
Name The name of the data stream API Name: name
type NewCreateDataStream ¶
type NewCreateDataStream func(name string) *CreateDataStream
NewCreateDataStream type alias for index.
func NewCreateDataStreamFunc ¶
func NewCreateDataStreamFunc(tp elastictransport.Interface) NewCreateDataStream
NewCreateDataStreamFunc returns a new instance of CreateDataStream with the provided transport. Used in the index of the library this allows to retrieve every apis in once place.