Documentation ¶
Overview ¶
Package surveyor is used to garner data from a NATS deployment for Prometheus
Package surveyor is used to garner data from a NATS deployment for Prometheus
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( DefaultListenPort = 7777 DefaultListenAddress = "0.0.0.0" DefaultURL = nats.DefaultURL DefaultExpectedServers = 3 DefaultPollTimeout = time.Second * 5 )
Defaults
Functions ¶
This section is empty.
Types ¶
type Options ¶
type Options struct { URLs string Credentials string PollTimeout time.Duration ExpectedServers int ListenAddress string ListenPort int CertFile string KeyFile string CaFile string NATSServerURL string HTTPUser string // User in metrics scrape by Prometheus. HTTPPassword string Prefix string // TODO }
Options are used to configure the NATS collector
func GetDefaultOptions ¶
func GetDefaultOptions() *Options
GetDefaultOptions returns the default set of options
type StatzCollector ¶
StatzCollector collects statz from a server deployment
func NewStatzCollector ¶
NewStatzCollector creates a NATS Statz Collector
func (*StatzCollector) Collect ¶
func (sc *StatzCollector) Collect(ch chan<- prometheus.Metric)
Collect gathers the streaming server serverz metrics.
func (*StatzCollector) Describe ¶
func (sc *StatzCollector) Describe(ch chan<- *prometheus.Desc)
Describe is the Prometheus interface to describe metrics for the prometheus system
func (*StatzCollector) Polling ¶
func (sc *StatzCollector) Polling() bool
Polling determines if the collector is in a polling cycle
Click to show internal directories.
Click to hide internal directories.