Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrNotFound is the error when the context does not contain a reqestID. ErrNotFound = errors.New("context does not contain a requestID") // ErrWrongType is the error when the value in the context has the wrong type. ErrWrongType = errors.New("value is not of type string") )
Functions ¶
func EchoMiddleware ¶
func EchoMiddleware() echo.MiddlewareFunc
EchoMiddleware puts the requestID into the context value.
func Get ¶
Get returns the stored value of the requestIDKey if no value is present (ErrNotFound) or for some reason the value is not a string (ErrWrongType) an error is returned.
func RestyMiddleware ¶
RestyMiddleware gets the requestID from the context and puts it into the header.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.