expvar2

package
Version: v2.5.1+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 4, 2019 License: Apache-2.0 Imports: 10 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EnviromentalVariables

func EnviromentalVariables() expvar.Var

EnviromentalVariables returns an expvar that also shows env variables

Types

type Handler

type Handler struct {
	Exported map[string]expvar.Var
	Logger   log.Logger
}

Handler can serve via HTTP expvar variables as well as custom variables inside Exported

func New

func New() *Handler

New creates and returns a new handler

func (*Handler) ServeHTTP

func (e *Handler) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP is a copy/past of the private expvar.expvarHandler that I sometimes want to register to my own handler.

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL