Documentation ¶
Index ¶
Constants ¶
View Source
const ( ReadBytesKey = attribute.Key("http.read_bytes") // if anything was read from the request body, the total number of bytes read ReadErrorKey = attribute.Key("http.read_error") // If an error occurred while reading a request, the string of the error (io.EOF is not recorded) WroteBytesKey = attribute.Key("http.wrote_bytes") // if anything was written to the response writer, the total number of bytes written WriteErrorKey = attribute.Key("http.write_error") // if an error occurred while writing a reply, the string of the error (io.EOF is not recorded) )
View Source
const ScopeName = "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp"
Variables ¶
This section is empty.
Functions ¶
func NewMiddleware ¶
func NewMiddleware() gin.HandlerFunc
NewMiddleware returns a tracing and metrics instrumentation middleware. The handler returned by the middleware wraps a handler in a span named after the operation and enriches it with metrics.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.