Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ErrOldReport = errors.New("More recent report already exists in storage")
ErrOldReport is an error returned if a more recent already exists on the storage while attempting to write a report for a cluster.
Functions ¶
func HandleServerError ¶
func HandleServerError(writer http.ResponseWriter, err error)
HandleServerError handles separate server errors and sends appropriate responses
Types ¶
type ForbiddenError ¶ added in v1.6.2
type ForbiddenError struct {
ErrString string
}
ForbiddenError means you don't have permission to do a particular action, for example your account belongs to a different organization
func (*ForbiddenError) Error ¶ added in v1.6.2
func (e *ForbiddenError) Error() string
type ItemNotFoundError ¶
type ItemNotFoundError struct {
ItemID interface{}
}
ItemNotFoundError shows that item with id ItemID wasn't found in the storage
func (*ItemNotFoundError) Error ¶
func (e *ItemNotFoundError) Error() string
Error returns error string
type MetricsConfiguration ¶ added in v1.21.9
type MetricsConfiguration struct { Job string `mapstructure:"job_name" toml:"job_name"` GatewayURL string `mapstructure:"gateway_url" toml:"gateway_url"` GatewayAuthToken string `mapstructure:"gateway_auth_token" toml:"gateway_auth_token"` TimeBetweenPush int `mapstructure:"time_between_push" toml:"time_between_push"` }
MetricsConfiguration holds metrics related configuration
type NoBodyError ¶
type NoBodyError struct{}
NoBodyError error meaning that client didn't provide body when it's required
func (*NoBodyError) Error ¶
func (*NoBodyError) Error() string
type RouterMissingParamError ¶
type RouterMissingParamError struct {
ParamName string
}
RouterMissingParamError missing parameter in request
func (*RouterMissingParamError) Error ¶
func (e *RouterMissingParamError) Error() string
type RouterParsingError ¶
RouterParsingError parsing error, for example string when we expected integer
func (*RouterParsingError) Error ¶
func (e *RouterParsingError) Error() string
type UnauthorizedError ¶ added in v1.6.2
type UnauthorizedError struct {
}UnauthorizedError means server can't authorize you, for example the token is missing or malformed
func (*UnauthorizedError) Error ¶ added in v1.6.2
func (e *UnauthorizedError) Error() string
type ValidationError ¶ added in v1.4.3
ValidationError validation error, for example when string is longer then expected
func (*ValidationError) Error ¶ added in v1.4.3
func (e *ValidationError) Error() string