Documentation ¶
Index ¶
- type Client
- type ClientOption
- type ClientService
- type HealthDefault
- func (o *HealthDefault) Code() int
- func (o *HealthDefault) Error() string
- func (o *HealthDefault) GetPayload() *httperrors.HTTPErrorResponse
- func (o *HealthDefault) IsClientError() bool
- func (o *HealthDefault) IsCode(code int) bool
- func (o *HealthDefault) IsRedirect() bool
- func (o *HealthDefault) IsServerError() bool
- func (o *HealthDefault) IsSuccess() bool
- func (o *HealthDefault) String() string
- type HealthInternalServerError
- func (o *HealthInternalServerError) Code() int
- func (o *HealthInternalServerError) Error() string
- func (o *HealthInternalServerError) GetPayload() *models.RestHealthResponse
- func (o *HealthInternalServerError) IsClientError() bool
- func (o *HealthInternalServerError) IsCode(code int) bool
- func (o *HealthInternalServerError) IsRedirect() bool
- func (o *HealthInternalServerError) IsServerError() bool
- func (o *HealthInternalServerError) IsSuccess() bool
- func (o *HealthInternalServerError) String() string
- type HealthOK
- func (o *HealthOK) Code() int
- func (o *HealthOK) Error() string
- func (o *HealthOK) GetPayload() *models.RestHealthResponse
- func (o *HealthOK) IsClientError() bool
- func (o *HealthOK) IsCode(code int) bool
- func (o *HealthOK) IsRedirect() bool
- func (o *HealthOK) IsServerError() bool
- func (o *HealthOK) IsSuccess() bool
- func (o *HealthOK) String() string
- type HealthParams
- func (o *HealthParams) SetContext(ctx context.Context)
- func (o *HealthParams) SetDefaults()
- func (o *HealthParams) SetHTTPClient(client *http.Client)
- func (o *HealthParams) SetService(service *string)
- func (o *HealthParams) SetTimeout(timeout time.Duration)
- func (o *HealthParams) WithContext(ctx context.Context) *HealthParams
- func (o *HealthParams) WithDefaults() *HealthParams
- func (o *HealthParams) WithHTTPClient(client *http.Client) *HealthParams
- func (o *HealthParams) WithService(service *string) *HealthParams
- func (o *HealthParams) WithTimeout(timeout time.Duration) *HealthParams
- func (o *HealthParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type HealthReader
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 health API
func (*Client) Health ¶
func (a *Client) Health(params *HealthParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*HealthOK, error)
Health performs a healthcheck
func (*Client) SetTransport ¶
func (a *Client) SetTransport(transport runtime.ClientTransport)
SetTransport changes the transport on the client
type ClientOption ¶ added in v0.13.1
type ClientOption func(*runtime.ClientOperation)
ClientOption may be used to customize the behavior of Client methods.
type ClientService ¶ added in v0.11.0
type ClientService interface { Health(params *HealthParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*HealthOK, 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 health API client.
func NewClientWithBasicAuth ¶ added in v0.32.0
func NewClientWithBasicAuth(host, basePath, scheme, user, password string) ClientService
New creates a new health API client with basic auth credentials. It takes the following parameters: - host: http host (github.com). - basePath: any base path for the API client ("/v1", "/v3"). - scheme: http scheme ("http", "https"). - user: user for basic authentication header. - password: password for basic authentication header.
func NewClientWithBearerToken ¶ added in v0.32.0
func NewClientWithBearerToken(host, basePath, scheme, bearerToken string) ClientService
New creates a new health API client with a bearer token for authentication. It takes the following parameters: - host: http host (github.com). - basePath: any base path for the API client ("/v1", "/v3"). - scheme: http scheme ("http", "https"). - bearerToken: bearer token for Bearer authentication header.
type HealthDefault ¶ added in v0.15.7
type HealthDefault struct { Payload *httperrors.HTTPErrorResponse // contains filtered or unexported fields }
HealthDefault describes a response with status code -1, with default header values.
Error
func NewHealthDefault ¶ added in v0.15.7
func NewHealthDefault(code int) *HealthDefault
NewHealthDefault creates a HealthDefault with default headers values
func (*HealthDefault) Code ¶ added in v0.15.7
func (o *HealthDefault) Code() int
Code gets the status code for the health default response
func (*HealthDefault) Error ¶ added in v0.15.7
func (o *HealthDefault) Error() string
func (*HealthDefault) GetPayload ¶ added in v0.15.7
func (o *HealthDefault) GetPayload() *httperrors.HTTPErrorResponse
func (*HealthDefault) IsClientError ¶ added in v0.19.3
func (o *HealthDefault) IsClientError() bool
IsClientError returns true when this health default response has a 4xx status code
func (*HealthDefault) IsCode ¶ added in v0.19.3
func (o *HealthDefault) IsCode(code int) bool
IsCode returns true when this health default response a status code equal to that given
func (*HealthDefault) IsRedirect ¶ added in v0.19.3
func (o *HealthDefault) IsRedirect() bool
IsRedirect returns true when this health default response has a 3xx status code
func (*HealthDefault) IsServerError ¶ added in v0.19.3
func (o *HealthDefault) IsServerError() bool
IsServerError returns true when this health default response has a 5xx status code
func (*HealthDefault) IsSuccess ¶ added in v0.19.3
func (o *HealthDefault) IsSuccess() bool
IsSuccess returns true when this health default response has a 2xx status code
func (*HealthDefault) String ¶ added in v0.19.3
func (o *HealthDefault) String() string
type HealthInternalServerError ¶
type HealthInternalServerError struct {
Payload *models.RestHealthResponse
}
HealthInternalServerError describes a response with status code 500, with default header values.
Unhealthy
func NewHealthInternalServerError ¶
func NewHealthInternalServerError() *HealthInternalServerError
NewHealthInternalServerError creates a HealthInternalServerError with default headers values
func (*HealthInternalServerError) Code ¶ added in v0.22.1
func (o *HealthInternalServerError) Code() int
Code gets the status code for the health internal server error response
func (*HealthInternalServerError) Error ¶
func (o *HealthInternalServerError) Error() string
func (*HealthInternalServerError) GetPayload ¶ added in v0.11.0
func (o *HealthInternalServerError) GetPayload() *models.RestHealthResponse
func (*HealthInternalServerError) IsClientError ¶ added in v0.19.3
func (o *HealthInternalServerError) IsClientError() bool
IsClientError returns true when this health internal server error response has a 4xx status code
func (*HealthInternalServerError) IsCode ¶ added in v0.19.3
func (o *HealthInternalServerError) IsCode(code int) bool
IsCode returns true when this health internal server error response a status code equal to that given
func (*HealthInternalServerError) IsRedirect ¶ added in v0.19.3
func (o *HealthInternalServerError) IsRedirect() bool
IsRedirect returns true when this health internal server error response has a 3xx status code
func (*HealthInternalServerError) IsServerError ¶ added in v0.19.3
func (o *HealthInternalServerError) IsServerError() bool
IsServerError returns true when this health internal server error response has a 5xx status code
func (*HealthInternalServerError) IsSuccess ¶ added in v0.19.3
func (o *HealthInternalServerError) IsSuccess() bool
IsSuccess returns true when this health internal server error response has a 2xx status code
func (*HealthInternalServerError) String ¶ added in v0.19.3
func (o *HealthInternalServerError) String() string
type HealthOK ¶
type HealthOK struct {
Payload *models.RestHealthResponse
}
HealthOK describes a response with status code 200, with default header values.
OK
func NewHealthOK ¶
func NewHealthOK() *HealthOK
NewHealthOK creates a HealthOK with default headers values
func (*HealthOK) GetPayload ¶ added in v0.11.0
func (o *HealthOK) GetPayload() *models.RestHealthResponse
func (*HealthOK) IsClientError ¶ added in v0.19.3
IsClientError returns true when this health o k response has a 4xx status code
func (*HealthOK) IsCode ¶ added in v0.19.3
IsCode returns true when this health o k response a status code equal to that given
func (*HealthOK) IsRedirect ¶ added in v0.19.3
IsRedirect returns true when this health o k response has a 3xx status code
func (*HealthOK) IsServerError ¶ added in v0.19.3
IsServerError returns true when this health o k response has a 5xx status code
type HealthParams ¶
type HealthParams struct { /* Service. return health for this specific service only */ Service *string Context context.Context HTTPClient *http.Client // contains filtered or unexported fields }
HealthParams contains all the parameters to send to the API endpoint
for the health operation. Typically these are written to a http.Request.
func NewHealthParams ¶
func NewHealthParams() *HealthParams
NewHealthParams creates a new HealthParams 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 NewHealthParamsWithContext ¶
func NewHealthParamsWithContext(ctx context.Context) *HealthParams
NewHealthParamsWithContext creates a new HealthParams object with the ability to set a context for a request.
func NewHealthParamsWithHTTPClient ¶
func NewHealthParamsWithHTTPClient(client *http.Client) *HealthParams
NewHealthParamsWithHTTPClient creates a new HealthParams object with the ability to set a custom HTTPClient for a request.
func NewHealthParamsWithTimeout ¶
func NewHealthParamsWithTimeout(timeout time.Duration) *HealthParams
NewHealthParamsWithTimeout creates a new HealthParams object with the ability to set a timeout on a request.
func (*HealthParams) SetContext ¶
func (o *HealthParams) SetContext(ctx context.Context)
SetContext adds the context to the health params
func (*HealthParams) SetDefaults ¶ added in v0.12.1
func (o *HealthParams) SetDefaults()
SetDefaults hydrates default values in the health params (not the query body).
All values with no default are reset to their zero value.
func (*HealthParams) SetHTTPClient ¶
func (o *HealthParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the health params
func (*HealthParams) SetService ¶ added in v0.16.3
func (o *HealthParams) SetService(service *string)
SetService adds the service to the health params
func (*HealthParams) SetTimeout ¶
func (o *HealthParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the health params
func (*HealthParams) WithContext ¶
func (o *HealthParams) WithContext(ctx context.Context) *HealthParams
WithContext adds the context to the health params
func (*HealthParams) WithDefaults ¶ added in v0.12.1
func (o *HealthParams) WithDefaults() *HealthParams
WithDefaults hydrates default values in the health params (not the query body).
All values with no default are reset to their zero value.
func (*HealthParams) WithHTTPClient ¶
func (o *HealthParams) WithHTTPClient(client *http.Client) *HealthParams
WithHTTPClient adds the HTTPClient to the health params
func (*HealthParams) WithService ¶ added in v0.16.3
func (o *HealthParams) WithService(service *string) *HealthParams
WithService adds the service to the health params
func (*HealthParams) WithTimeout ¶
func (o *HealthParams) WithTimeout(timeout time.Duration) *HealthParams
WithTimeout adds the timeout to the health params
func (*HealthParams) WriteToRequest ¶
func (o *HealthParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type HealthReader ¶
type HealthReader struct {
// contains filtered or unexported fields
}
HealthReader is a Reader for the Health structure.
func (*HealthReader) ReadResponse ¶
func (o *HealthReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.