observability

package
v0.10.2 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2026 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package observability provides metrics, profiling, and etc.

Package observability provides metrics, profiling, and etc.

Index

Constants

This section is empty.

Variables

View Source
var (
	// RootScope is the root scope for all metrics.
	RootScope = meter.NewHierarchicalScope("banyandb", "_")
	// SystemScope is the system scope for all metrics.
	SystemScope = RootScope.SubScope("system")
)
View Source
var BypassRegistry = NewBypassRegistry()

BypassRegistry is a MetricsRegistry that does not collect any metrics.

Functions

func NewProfService

func NewProfService() run.Service

NewProfService returns a pprof service.

Types

type Factory added in v0.7.0

type Factory interface {
	NewCounter(name string, labelNames ...string) meter.Counter
	NewGauge(name string, labelNames ...string) meter.Gauge
	NewHistogram(name string, buckets meter.Buckets, labelNames ...string) meter.Histogram
}

Factory is the factory for creating metrics.

type MetricsRegistry added in v0.7.0

type MetricsRegistry interface {
	run.Service
	// With returns a factory with the given scope.
	With(scope meter.Scope) Factory
	// NativeEnabled returns whether the native mode is enabled.
	NativeEnabled() bool
}

MetricsRegistry is the interface for metrics registry.

func NewBypassRegistry added in v0.9.0

func NewBypassRegistry() MetricsRegistry

NewBypassRegistry creates a new instance of bypassMetricsRegistry.

Directories

Path Synopsis
Package services is the service provider of observability real works.
Package services is the service provider of observability real works.

Jump to

Keyboard shortcuts

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