Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdminMetrics ¶
type AdminMetrics struct{}
AdminMetrics is a module that serves a metrics endpoint so that any gathered metrics can be exposed for scraping. This module is not configurable, and is permanently mounted to the admin API endpoint at "/metrics". See the Metrics module for a configurable endpoint that is usable if the Admin API is disabled.
func (AdminMetrics) KengineModule ¶
func (AdminMetrics) KengineModule() kengine.ModuleInfo
KengineModule returns the Kengine module information.
func (*AdminMetrics) Routes ¶
func (m *AdminMetrics) Routes() []kengine.AdminRoute
Routes returns a route for the /metrics endpoint.
type Metrics ¶
type Metrics struct { // Disable OpenMetrics negotiation, enabled by default. May be necessary if // the produced metrics cannot be parsed by the service scraping metrics. DisableOpenMetrics bool `json:"disable_openmetrics,omitempty"` // contains filtered or unexported fields }
Metrics is a module that serves a /metrics endpoint so that any gathered metrics can be exposed for scraping. This module is configurable by end-users unlike AdminMetrics.
func (Metrics) KengineModule ¶
func (Metrics) KengineModule() kengine.ModuleInfo
KengineModule returns the Kengine module information.
func (Metrics) ServeHTTP ¶
func (m Metrics) ServeHTTP(w http.ResponseWriter, r *http.Request, next kenginehttp.Handler) error
func (*Metrics) UnmarshalKenginefile ¶
func (m *Metrics) UnmarshalKenginefile(d *kenginefile.Dispenser) error
UnmarshalKenginefile sets up the handler from Kenginefile tokens. Syntax:
metrics [<matcher>] { disable_openmetrics }