Documentation ¶
Overview ¶
Package httpstats provides shims for writing webutil logger events to a stats collector.
Index ¶
Constants ¶
View Source
const ( MetricNameHTTPRequest string = string(webutil.FlagHTTPRequest) MetricNameHTTPRequestSize string = MetricNameHTTPRequest + ".size" MetricNameHTTPRequestElapsed string = MetricNameHTTPRequest + ".elapsed" TagRoute string = "route" TagMethod string = "method" TagStatus string = "status" RouteNotFound string = "not_found" )
HTTP stats constants
Variables ¶
This section is empty.
Functions ¶
func AddListeners ¶
func AddListeners(log logger.FilterListenable, collector stats.Collector, opts ...AddListenerOption)
AddListeners adds web listeners.
Types ¶
type AddListenerOption ¶
type AddListenerOption func(*AddListenerOptions)
AddListenerOption mutates AddListenerOptions
type AddListenerOptions ¶
type AddListenerOptions struct {
RequestSanitizeDefaults []sanitize.RequestOption
}
AddListenerOptions are options for adding listeners.
Click to show internal directories.
Click to hide internal directories.