Documentation ¶
Index ¶
- Constants
- Variables
- func InitTelemetry(logger *zap.Logger, config *Config) (metric.MeterProvider, error)
- func RegisterExtraMetrics(selectors []string, mp metric.MeterProvider)
- func StartServer(exporter *prometheus.Exporter, logger *zap.Logger, port string) error
- type Config
- type OtlpGrpcConfig
- type PrometheusConfig
- type StdoutConfig
Constants ¶
View Source
const ( KindlingServiceNamePrefix = "kindling" StdoutKindExporter = "stdout" OtlpGrpcKindExporter = "otlp" PrometheusKindExporter = "prometheus" )
View Source
const Int64BoundaryMultiplier = 1e6
Variables ¶
View Source
var DefaultConfig = Config{ ExportKind: "stdout", PromCfg: nil, OtlpGrpcCfg: nil, StdoutCfg: &StdoutConfig{CollectPeriod: 10 * time.Second}, }
Functions ¶
func InitTelemetry ¶
func RegisterExtraMetrics ¶
func RegisterExtraMetrics(selectors []string, mp metric.MeterProvider)
func StartServer ¶
Types ¶
type Config ¶
type Config struct { ExportKind string `mapstructure:"export_kind"` PromCfg *PrometheusConfig `mapstructure:"prometheus"` OtlpGrpcCfg *OtlpGrpcConfig `mapstructure:"otlp"` StdoutCfg *StdoutConfig `mapstructure:"stdout"` }
type OtlpGrpcConfig ¶
type PrometheusConfig ¶
type StdoutConfig ¶
Click to show internal directories.
Click to hide internal directories.