metrics

package
v0.0.0-...-99a34e4 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const InternalActorMetrics string = "internal.actor.metrics"
View Source
const LibName string = "protoactor"

Variables

This section is empty.

Functions

This section is empty.

Types

type ActorMetrics

type ActorMetrics struct {

	// MetricsID
	ID string

	// Actors
	ActorFailureCount            metric.Int64Counter
	ActorMailboxLength           metric.Int64ObservableGauge
	ActorMessageReceiveHistogram metric.Float64Histogram
	ActorRestartedCount          metric.Int64Counter
	ActorSpawnCount              metric.Int64Counter
	ActorStoppedCount            metric.Int64Counter

	// Deadletters
	DeadLetterCount metric.Int64Counter

	// Futures
	FuturesStartedCount   metric.Int64Counter
	FuturesCompletedCount metric.Int64Counter
	FuturesTimedOutCount  metric.Int64Counter

	// Threadpool
	ThreadPoolLatency metric.Int64Histogram
	// contains filtered or unexported fields
}

func NewActorMetrics

func NewActorMetrics(logger *slog.Logger) *ActorMetrics

NewActorMetrics creates a new ActorMetrics value and returns a pointer to it

func (*ActorMetrics) SetActorMailboxLengthGauge

func (am *ActorMetrics) SetActorMailboxLengthGauge(gauge metric.Int64ObservableGauge)

SetActorMailboxLengthGauge makes sure access to ActorMailboxLength is sequenced

type ProtoMetrics

type ProtoMetrics struct {
	// contains filtered or unexported fields
}

func NewProtoMetrics

func NewProtoMetrics(logger *slog.Logger) *ProtoMetrics

func (*ProtoMetrics) Get

func (pm *ProtoMetrics) Get(key string) *ActorMetrics

func (*ProtoMetrics) Instruments

func (pm *ProtoMetrics) Instruments() *ActorMetrics

func (*ProtoMetrics) Register

func (pm *ProtoMetrics) Register(key string, instance *ActorMetrics)

Jump to

Keyboard shortcuts

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