Documentation
¶
Overview ¶
Package ppechov4 instruments the labstack/echo/v4 package (https://github.com/labstack/echo).
This package instruments inbound requests handled by a echo.Router. Register the Middleware as the middleware of the router to trace all handlers:
e := echo.New() e.Use(ppechov4.Middleware())
Use WrapHandler to select the handlers you want to track:
e.GET("/hello", ppechov4.WrapHandler(hello))
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Middleware ¶
func Middleware() echo.MiddlewareFunc
Middleware returns an echo middleware that creates a pinpoint.Tracer that instruments the echo handler function.
func WrapHandler ¶
func WrapHandler(handler echo.HandlerFunc) echo.HandlerFunc
WrapHandler wraps the given echo handler and adds the pinpoint.Tracer to the request's context. By using the pinpoint.FromContext function, this tracer can be obtained.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.