Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DummyMetrics ¶
type DummyMetrics struct { }
DummyMetrics implements the Instrumenter for testing
func NewDummyMetrics ¶
func NewDummyMetrics() *DummyMetrics
NewDummyMetrics returns a new DummyMetrics object
func (*DummyMetrics) IncNodeDrainFail ¶
func (p *DummyMetrics) IncNodeDrainFail()
IncNodeDrainFail is a fake to implement the Instrumenter interface
func (*DummyMetrics) IncNodeDrainTotal ¶
func (p *DummyMetrics) IncNodeDrainTotal()
IncNodeDrainTotal is a fake to implement the Instrumenter interface
func (*DummyMetrics) IncNodeReapFail ¶
func (p *DummyMetrics) IncNodeReapFail()
IncNodeReapFail is a fake to implement the Instrumenter interface
func (*DummyMetrics) IncNodeReapTotal ¶
func (p *DummyMetrics) IncNodeReapTotal()
IncNodeReapTotal is a fake to implement the Instrumenter interface
type Instrumenter ¶
type Instrumenter interface { IncNodeDrainTotal() IncNodeDrainFail() IncNodeReapTotal() IncNodeReapFail() }
Instrumenter is the interface that will collect the metrics and has ability to send/expose those metrics.
type PromMetrics ¶
type PromMetrics struct {
// contains filtered or unexported fields
}
PromMetrics implements the Instrumenter so the metrics can be managed by Prometheus
func NewPrometheusMetrics ¶
func NewPrometheusMetrics(path string, mux *http.ServeMux) *PromMetrics
NewPrometheusMetrics returns a new PromMetrics object
func (*PromMetrics) IncNodeDrainFail ¶
func (p *PromMetrics) IncNodeDrainFail()
IncNodeDrainFail adds one to the nodeDrainFail counter
func (*PromMetrics) IncNodeDrainTotal ¶
func (p *PromMetrics) IncNodeDrainTotal()
IncNodeDrainTotal adds one to the nodeDrainTotal counter
func (*PromMetrics) IncNodeReapFail ¶
func (p *PromMetrics) IncNodeReapFail()
IncNodeReapFail adds one to the nodeReapFail counter
func (*PromMetrics) IncNodeReapTotal ¶
func (p *PromMetrics) IncNodeReapTotal()
IncNodeReapTotal adds one to the nodeReapTotal counter