mora

package
v0.0.0-...-929fc3c Latest Latest
Warning

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

Go to latest
Published: Dec 8, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

func GetLogger

func GetLogger() *logger.Logger

GetLogger returns the global logger instance

func GetTracer

func GetTracer() trace.Tracer

GetTracer returns the global tracer instance

func GetZapLogger

func GetZapLogger() *zap.Logger

GetZapLogger returns the underlying zap.Logger from the mora logger

func InitLogger

func InitLogger(serviceName string, env string) error

InitLogger initializes the Mora logger

func InitObservability

func InitObservability(serviceName, exporterURL, env string) error

InitObservability initializes OpenTelemetry tracing

func LoadConfig

func LoadConfig(configPath string) (*viper.Viper, error)

LoadConfig loads configuration using Mora config package

func LoadConfigWithDefaults

func LoadConfigWithDefaults(configName string, configPaths []string) (*viper.Viper, error)

LoadConfigWithDefaults loads configuration with default values

func NewConfigLoader

func NewConfigLoader() *config.Loader

NewConfigLoader creates a new config loader

func ShutdownObservability

func ShutdownObservability(ctx context.Context) error

ShutdownObservability gracefully shuts down observability

func StartSpan

func StartSpan(ctx context.Context, name string) (context.Context, trace.Span)

StartSpan starts a new span

func Sync

func Sync()

Sync flushes any buffered log entries

Types

This section is empty.

Jump to

Keyboard shortcuts

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