metrics

package
v0.0.0-...-57c47fe Latest Latest
Warning

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

Go to latest
Published: May 30, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	CrawlLabel = prometheus.Labels{"type": "crawl"}
	DialLabel  = prometheus.Labels{"type": "dial"}
)
View Source
var (
	VisitCount = promauto.NewCounterVec(prometheus.CounterOpts{
		Name:      "visit_count",
		Namespace: "nebula",
		Help:      "The number of visits",
	}, []string{"type"})
	VisitErrorsCount = promauto.NewCounterVec(prometheus.CounterOpts{
		Name:      "visit_error_count",
		Namespace: "nebula",
		Help:      "The number of visits that yielded an error",
	}, []string{"type"})
	FetchedNeighborsCount = promauto.NewHistogram(prometheus.HistogramOpts{
		Name:      "fetched_neighbors_count",
		Namespace: "nebula",
		Help:      "Number of neighbors fetched from a peer",
		Buckets:   []float64{100, 150, 200, 210, 220, 230, 240, 250, 260, 270, 280, 290, 300},
	})
	DistinctVisitedPeersCount = promauto.NewGauge(prometheus.GaugeOpts{
		Name:      "distinct_visited_peers_count",
		Namespace: "nebula",
		Help:      "Number of distinct peers found for a peer crawl",
	})
	VisitQueueLength = promauto.NewGaugeVec(prometheus.GaugeOpts{
		Name:      "visit_queue_length",
		Namespace: "nebula",
		Help:      "Number of peers in the queue to visit",
	}, []string{"type"})
	CacheQueriesCount = promauto.NewCounterVec(prometheus.CounterOpts{
		Name:      "cache_queries",
		Namespace: "nebula",
		Help:      "The number of cache queries",
	}, []string{"entity", "outcome"})
	InsertVisitHistogram = prometheus.NewHistogramVec(prometheus.HistogramOpts{
		Name: "insert_visit_query_duration_seconds",
		Help: "Histogram of database query times for visit insertions",
	}, []string{"type", "success"})
)

Functions

func ListenAndServe

func ListenAndServe(host string, port int)

Types

This section is empty.

Jump to

Keyboard shortcuts

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