Documentation
¶
Overview ¶
Package goqueue provides dependency-neutral handler instrumentation for queue. Message values and raw handler errors are never inspected.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WrapHandler ¶
func WrapHandler[Message any]( instrumenter *Instrumenter, handler func(context.Context, Message) error, ) func(context.Context, Message) error
WrapHandler instruments any queue-compatible handler signature without importing or inspecting its message type.
Types ¶
type Backend ¶
type Backend string
Backend is a finite queue backend label.
const ( // BackendMemory identifies the in-memory queue. BackendMemory Backend = "memory" // BackendRedis identifies the Redis list queue. BackendRedis Backend = "redis" // BackendRedisStream identifies Redis Streams. BackendRedisStream Backend = "redis_stream" // BackendValkeyStream identifies Valkey Streams. BackendValkeyStream Backend = "valkey_stream" // BackendNATS identifies NATS. BackendNATS Backend = "nats" // BackendNSQ identifies NSQ. BackendNSQ Backend = "nsq" // BackendRabbitMQ identifies RabbitMQ. BackendRabbitMQ Backend = "rabbitmq" // BackendOther collapses an explicitly supported custom backend. BackendOther Backend = "other" )
type Config ¶
type Config struct {
Backend Backend
TracerProvider trace.TracerProvider
MeterProvider metric.MeterProvider
}
Config selects the fixed backend and standard providers.
type Instrumenter ¶
type Instrumenter struct {
// contains filtered or unexported fields
}
Instrumenter owns bounded queue handler instruments.
func New ¶
func New(config Config) (*Instrumenter, error)
New constructs a dependency-neutral queue instrumenter.
Click to show internal directories.
Click to hide internal directories.