metrics

package
v1.14.0 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client for metrics API

func (*Client) GetMetrics

func (a *Client) GetMetrics(params *GetMetricsParams, opts ...ClientOption) (*GetMetricsOK, error)

GetMetrics retrieves cilium metrics

func (*Client) SetTransport

func (a *Client) SetTransport(transport runtime.ClientTransport)

SetTransport changes the transport on the client

type ClientOption added in v1.14.0

type ClientOption func(*runtime.ClientOperation)

ClientOption is the option for Client methods

type ClientService added in v1.14.0

type ClientService interface {
	GetMetrics(params *GetMetricsParams, opts ...ClientOption) (*GetMetricsOK, error)

	SetTransport(transport runtime.ClientTransport)
}

ClientService is the interface for Client methods

func New

func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService

New creates a new metrics API client.

type GetMetricsInternalServerError

type GetMetricsInternalServerError struct {
}

GetMetricsInternalServerError describes a response with status code 500, with default header values.

Metrics cannot be retrieved

func NewGetMetricsInternalServerError

func NewGetMetricsInternalServerError() *GetMetricsInternalServerError

NewGetMetricsInternalServerError creates a GetMetricsInternalServerError with default headers values

func (*GetMetricsInternalServerError) Error

func (*GetMetricsInternalServerError) IsClientError added in v1.14.0

func (o *GetMetricsInternalServerError) IsClientError() bool

IsClientError returns true when this get metrics internal server error response has a 4xx status code

func (*GetMetricsInternalServerError) IsCode added in v1.14.0

func (o *GetMetricsInternalServerError) IsCode(code int) bool

IsCode returns true when this get metrics internal server error response a status code equal to that given

func (*GetMetricsInternalServerError) IsRedirect added in v1.14.0

func (o *GetMetricsInternalServerError) IsRedirect() bool

IsRedirect returns true when this get metrics internal server error response has a 3xx status code

func (*GetMetricsInternalServerError) IsServerError added in v1.14.0

func (o *GetMetricsInternalServerError) IsServerError() bool

IsServerError returns true when this get metrics internal server error response has a 5xx status code

func (*GetMetricsInternalServerError) IsSuccess added in v1.14.0

func (o *GetMetricsInternalServerError) IsSuccess() bool

IsSuccess returns true when this get metrics internal server error response has a 2xx status code

func (*GetMetricsInternalServerError) String added in v1.14.0

type GetMetricsOK

type GetMetricsOK struct {
	Payload []*models.Metric
}

GetMetricsOK describes a response with status code 200, with default header values.

Success

func NewGetMetricsOK

func NewGetMetricsOK() *GetMetricsOK

NewGetMetricsOK creates a GetMetricsOK with default headers values

func (*GetMetricsOK) Error

func (o *GetMetricsOK) Error() string

func (*GetMetricsOK) GetPayload added in v1.14.0

func (o *GetMetricsOK) GetPayload() []*models.Metric

func (*GetMetricsOK) IsClientError added in v1.14.0

func (o *GetMetricsOK) IsClientError() bool

IsClientError returns true when this get metrics o k response has a 4xx status code

func (*GetMetricsOK) IsCode added in v1.14.0

func (o *GetMetricsOK) IsCode(code int) bool

IsCode returns true when this get metrics o k response a status code equal to that given

func (*GetMetricsOK) IsRedirect added in v1.14.0

func (o *GetMetricsOK) IsRedirect() bool

IsRedirect returns true when this get metrics o k response has a 3xx status code

func (*GetMetricsOK) IsServerError added in v1.14.0

func (o *GetMetricsOK) IsServerError() bool

IsServerError returns true when this get metrics o k response has a 5xx status code

func (*GetMetricsOK) IsSuccess added in v1.14.0

func (o *GetMetricsOK) IsSuccess() bool

IsSuccess returns true when this get metrics o k response has a 2xx status code

func (*GetMetricsOK) String added in v1.14.0

func (o *GetMetricsOK) String() string

type GetMetricsParams

type GetMetricsParams struct {
	Context    context.Context
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

GetMetricsParams contains all the parameters to send to the API endpoint

for the get metrics operation.

Typically these are written to a http.Request.

func NewGetMetricsParams

func NewGetMetricsParams() *GetMetricsParams

NewGetMetricsParams creates a new GetMetricsParams object, with the default timeout for this client.

Default values are not hydrated, since defaults are normally applied by the API server side.

To enforce default values in parameter, use SetDefaults or WithDefaults.

func NewGetMetricsParamsWithContext

func NewGetMetricsParamsWithContext(ctx context.Context) *GetMetricsParams

NewGetMetricsParamsWithContext creates a new GetMetricsParams object with the ability to set a context for a request.

func NewGetMetricsParamsWithHTTPClient

func NewGetMetricsParamsWithHTTPClient(client *http.Client) *GetMetricsParams

NewGetMetricsParamsWithHTTPClient creates a new GetMetricsParams object with the ability to set a custom HTTPClient for a request.

func NewGetMetricsParamsWithTimeout

func NewGetMetricsParamsWithTimeout(timeout time.Duration) *GetMetricsParams

NewGetMetricsParamsWithTimeout creates a new GetMetricsParams object with the ability to set a timeout on a request.

func (*GetMetricsParams) SetContext

func (o *GetMetricsParams) SetContext(ctx context.Context)

SetContext adds the context to the get metrics params

func (*GetMetricsParams) SetDefaults added in v1.14.0

func (o *GetMetricsParams) SetDefaults()

SetDefaults hydrates default values in the get metrics params (not the query body).

All values with no default are reset to their zero value.

func (*GetMetricsParams) SetHTTPClient

func (o *GetMetricsParams) SetHTTPClient(client *http.Client)

SetHTTPClient adds the HTTPClient to the get metrics params

func (*GetMetricsParams) SetTimeout

func (o *GetMetricsParams) SetTimeout(timeout time.Duration)

SetTimeout adds the timeout to the get metrics params

func (*GetMetricsParams) WithContext

func (o *GetMetricsParams) WithContext(ctx context.Context) *GetMetricsParams

WithContext adds the context to the get metrics params

func (*GetMetricsParams) WithDefaults added in v1.14.0

func (o *GetMetricsParams) WithDefaults() *GetMetricsParams

WithDefaults hydrates default values in the get metrics params (not the query body).

All values with no default are reset to their zero value.

func (*GetMetricsParams) WithHTTPClient

func (o *GetMetricsParams) WithHTTPClient(client *http.Client) *GetMetricsParams

WithHTTPClient adds the HTTPClient to the get metrics params

func (*GetMetricsParams) WithTimeout

func (o *GetMetricsParams) WithTimeout(timeout time.Duration) *GetMetricsParams

WithTimeout adds the timeout to the get metrics params

func (*GetMetricsParams) WriteToRequest

func (o *GetMetricsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error

WriteToRequest writes these params to a swagger request

type GetMetricsReader

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

GetMetricsReader is a Reader for the GetMetrics structure.

func (*GetMetricsReader) ReadResponse

func (o *GetMetricsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)

ReadResponse reads a server response into the received o.

Jump to

Keyboard shortcuts

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