Documentation
¶
Index ¶
- func ContextRecords(key interface{}, factory record.Factory) record.Factory
- func ContextWithLogger(ctx context.Context, logger *zap.Logger) context.Context
- func DoWithContextRecords(ctx context.Context, do func(ctx context.Context) error, actionName string, ...) error
- func DoWithRecords(ctx context.Context, do func(ctx context.Context) error, ...) error
- func EasyRecorders(desc string) record.Factory
- func ExtraFromContext(ctx context.Context) record.Factory
- func ExtraLoggerFromContext(ctx context.Context) *zap.Logger
- func SetToContext(ctx context.Context, factory record.Factory) context.Context
- type Factory
- type LoggerFactory
- type LoggerRecorder
- type PromFactory
- type PromRecorder
- type TracerFactory
- type TracerRecorder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ContextWithLogger ¶
func DoWithContextRecords ¶
func DoWithRecords ¶
func DoWithRecords(ctx context.Context, do func(ctx context.Context) error, factory record.Factory, actionName string, field ...record.Field) error
help function
func EasyRecorders ¶
Types ¶
type Factory ¶
type Factory struct { Desc string PromFactory func() *PromFactory TracerFactory func() *TracerFactory LoggerFactory func() *LoggerFactory }
type LoggerFactory ¶
type LoggerFactory struct {
// contains filtered or unexported fields
}
func NewLoggerRecorderFactory ¶
func NewLoggerRecorderFactory(logger *zap.Logger, messageDesc string) *LoggerFactory
type LoggerRecorder ¶
type LoggerRecorder struct {
// contains filtered or unexported fields
}
type PromFactory ¶
type PromFactory struct {
// contains filtered or unexported fields
}
func NewPromRecorderFactory ¶
func NewPromRecorderFactory(name string, fields ...string) *PromFactory
type PromRecorder ¶
type PromRecorder struct {
// contains filtered or unexported fields
}
type TracerFactory ¶
type TracerFactory struct {
// contains filtered or unexported fields
}
func NewTracerFactory ¶
func NewTracerFactory(tracer opentracing.Tracer) *TracerFactory
type TracerRecorder ¶
type TracerRecorder struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.