Documentation ¶
Index ¶
- Constants
- type Config
- type Gauge
- type Service
- func (s *Service) HTTPMiddleware(next http.Handler) http.Handler
- func (s *Service) Registry() prometheus.Registerer
- func (s *Service) RestfulMiddleWare(req *restful.Request, resp *restful.Response, chain *restful.FilterChain)
- func (s *Service) RestfulWebService() *restful.WebService
- func (s *Service) ServeHTTP(resp http.ResponseWriter, req *http.Request)
Constants ¶
View Source
const ( LabelHandler = "handler" LabelHTTPStatus = "status_code" LabelOrigin = "origin" LabelProcessName = "process_name" LabelHost = "host" LabelAppCode = "app_code" LabelUser = "user" LabelRealIP = "real_ip" )
labels
View Source
const (
KeySelectedRoutePath string = "SelectedRoutePath"
)
labels
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Gauge ¶
type Gauge struct {
// contains filtered or unexported fields
}
func NewGauge ¶
func NewGauge(opt prometheus.GaugeOpts) *Gauge
func (*Gauge) Collect ¶
func (g *Gauge) Collect(ch chan<- prometheus.Metric)
func (*Gauge) Describe ¶
func (g *Gauge) Describe(ch chan<- *prometheus.Desc)
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service an http service
func (*Service) HTTPMiddleware ¶
HTTPMiddleware is the http middleware for go-restful framework
func (*Service) Registry ¶
func (s *Service) Registry() prometheus.Registerer
Registry returns the prometheus.Registerer
func (*Service) RestfulMiddleWare ¶
func (s *Service) RestfulMiddleWare(req *restful.Request, resp *restful.Response, chain *restful.FilterChain)
RestfulMiddleWare is the http middleware for go-restful framework
func (*Service) RestfulWebService ¶
func (s *Service) RestfulWebService() *restful.WebService
RestfulWebService is the http WebService for go-restful framework
Click to show internal directories.
Click to hide internal directories.