endpoints

package
v0.10.2 Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2019 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ResDeploymentStarted              = "deployment started"
	ResDeploymentUpdated              = "deployment updated"
	ResDeploymentDeleted              = "deployment deleted"
	ResDeploymentUpToDate             = "deployment is up-to-date"
	ResDeploymentUpToDateUpdating     = "deployment is already updating"
	ResDifferentDeploymentUpdating    = "previous deployment is currently updating, use --force to override"
	ResCachedDeletedDeploymentStarted = "cache deleted, deployment started"
)

Variables

This section is empty.

Functions

func Delete

func Delete(w http.ResponseWriter, r *http.Request)

func Deploy

func Deploy(w http.ResponseWriter, r *http.Request)

func ErrorAnyPathParamRequired added in v0.4.0

func ErrorAnyPathParamRequired(params ...string) error

func ErrorAnyQueryParamRequired added in v0.4.0

func ErrorAnyQueryParamRequired(params ...string) error

func ErrorAppNotDeployed added in v0.4.0

func ErrorAppNotDeployed(appName string) error

func ErrorAuthAPIError

func ErrorAuthAPIError() error

func ErrorAuthHeaderMalformed

func ErrorAuthHeaderMalformed() error

func ErrorAuthHeaderMissing

func ErrorAuthHeaderMissing() error

func ErrorAuthInvalid added in v0.10.0

func ErrorAuthInvalid() error

func ErrorAuthOtherAccount added in v0.10.0

func ErrorAuthOtherAccount() error

func ErrorFormFileMustBeProvided added in v0.4.0

func ErrorFormFileMustBeProvided(fileName string) error

func ErrorPathParamRequired added in v0.4.0

func ErrorPathParamRequired(param string) error

func ErrorPending added in v0.4.0

func ErrorPending() error

func ErrorQueryParamRequired added in v0.4.0

func ErrorQueryParamRequired(param string) error

func GetDeployments added in v0.7.0

func GetDeployments(w http.ResponseWriter, r *http.Request)

func GetMetrics added in v0.8.0

func GetMetrics(w http.ResponseWriter, r *http.Request)

func GetResources

func GetResources(w http.ResponseWriter, r *http.Request)

func Info added in v0.10.0

func Info(w http.ResponseWriter, r *http.Request)

func ReadLogs

func ReadLogs(w http.ResponseWriter, r *http.Request)

func RecoverAndRespond

func RecoverAndRespond(w http.ResponseWriter, strs ...string)

func Respond

func Respond(w http.ResponseWriter, response interface{})

func RespondError

func RespondError(w http.ResponseWriter, err error, strs ...string)

func RespondErrorCode

func RespondErrorCode(w http.ResponseWriter, code int, err error, strs ...string)

Types

type Error added in v0.2.0

type Error struct {
	Kind ErrorKind
	// contains filtered or unexported fields
}

func (Error) Error added in v0.2.0

func (e Error) Error() string

type ErrorKind

type ErrorKind int
const (
	ErrUnknown ErrorKind = iota
	ErrAuthHeaderMissing
	ErrAuthHeaderMalformed
	ErrAuthAPIError
	ErrAuthInvalid
	ErrAuthOtherAccount
	ErrAppNotDeployed
	ErrFormFileMustBeProvided
	ErrQueryParamRequired
	ErrPathParamRequired
	ErrAnyQueryParamRequired
	ErrAnyPathParamRequired
	ErrPending
)

func (ErrorKind) MarshalBinary

func (t ErrorKind) MarshalBinary() ([]byte, error)

MarshalBinary satisfies BinaryMarshaler

func (ErrorKind) MarshalText

func (t ErrorKind) MarshalText() ([]byte, error)

MarshalText satisfies TextMarshaler

func (ErrorKind) String

func (t ErrorKind) String() string

func (*ErrorKind) UnmarshalBinary

func (t *ErrorKind) UnmarshalBinary(data []byte) error

UnmarshalBinary satisfies BinaryUnmarshaler Needed for msgpack

func (*ErrorKind) UnmarshalText

func (t *ErrorKind) UnmarshalText(text []byte) error

UnmarshalText satisfies TextUnmarshaler

Jump to

Keyboard shortcuts

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