metrics

package
v1.15.0-pre.3 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2023 License: Apache-2.0 Imports: 5 Imported by: 3

Documentation

Index

Constants

View Source
const GetMetricsFailedCode int = 500

GetMetricsFailedCode is the HTTP code returned for type GetMetricsFailed

View Source
const GetMetricsOKCode int = 200

GetMetricsOKCode is the HTTP code returned for type GetMetricsOK

Variables

This section is empty.

Functions

This section is empty.

Types

type GetMetrics

type GetMetrics struct {
	Context *middleware.Context
	Handler GetMetricsHandler
}
GetMetrics swagger:route GET /metrics/ metrics getMetrics

Retrieve cilium operator metrics

func NewGetMetrics

func NewGetMetrics(ctx *middleware.Context, handler GetMetricsHandler) *GetMetrics

NewGetMetrics creates a new http.Handler for the get metrics operation

func (*GetMetrics) ServeHTTP

func (o *GetMetrics) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type GetMetricsFailed

type GetMetricsFailed struct {
}

GetMetricsFailed Metrics cannot be retrieved

swagger:response getMetricsFailed

func NewGetMetricsFailed

func NewGetMetricsFailed() *GetMetricsFailed

NewGetMetricsFailed creates GetMetricsFailed with default headers values

func (*GetMetricsFailed) WriteResponse

func (o *GetMetricsFailed) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetMetricsHandler

type GetMetricsHandler interface {
	Handle(GetMetricsParams) middleware.Responder
}

GetMetricsHandler interface for that can handle valid get metrics params

type GetMetricsHandlerFunc

type GetMetricsHandlerFunc func(GetMetricsParams) middleware.Responder

GetMetricsHandlerFunc turns a function with the right signature into a get metrics handler

func (GetMetricsHandlerFunc) Handle

Handle executing the request and returning a response

type GetMetricsOK

type GetMetricsOK struct {

	/*
	  In: Body
	*/
	Payload []*models.Metric `json:"body,omitempty"`
}

GetMetricsOK Success

swagger:response getMetricsOK

func NewGetMetricsOK

func NewGetMetricsOK() *GetMetricsOK

NewGetMetricsOK creates GetMetricsOK with default headers values

func (*GetMetricsOK) SetPayload

func (o *GetMetricsOK) SetPayload(payload []*models.Metric)

SetPayload sets the payload to the get metrics o k response

func (*GetMetricsOK) WithPayload

func (o *GetMetricsOK) WithPayload(payload []*models.Metric) *GetMetricsOK

WithPayload adds the payload to the get metrics o k response

func (*GetMetricsOK) WriteResponse

func (o *GetMetricsOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetMetricsParams

type GetMetricsParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`
}

GetMetricsParams contains all the bound params for the get metrics operation typically these are obtained from a http.Request

swagger:parameters GetMetrics

func NewGetMetricsParams

func NewGetMetricsParams() GetMetricsParams

NewGetMetricsParams creates a new GetMetricsParams object

There are no default values defined in the spec.

func (*GetMetricsParams) BindRequest

func (o *GetMetricsParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewGetMetricsParams() beforehand.

Jump to

Keyboard shortcuts

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