l

package module
v1.5.2 Latest Latest
Warning

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

Go to latest
Published: Feb 10, 2025 License: MIT Imports: 14 Imported by: 10

README

Advanced Structured Logging Framework for Go

A high-performance, feature-rich structured logging framework for Go applications with support for asynchronous writes, log rotation, Metrics collection, and more.

Features

  • Structured Logging: JSON and text format support with key-value pairs
  • Asynchronous Writing: Non-blocking log writes with configurable buffer size
  • Log Rotation: Automatic file rotation based on size with configurable backups
  • Metrics Collection: Built-in logging Metrics and performance monitoring
  • Health Checking: Integrated health monitoring system
  • Error Handling: Comprehensive error handling with panic recovery
  • Context Support: Context propagation through logging chain
  • Flexible Output: Support for multiple output formats and destinations
  • Performance Optimized: High-throughput logging with batched writes
  • Extensible: Interface-based design for easy customization

Installation

go get github.com/baditaflorin/l

Quick Start

package main

import (
    "github.com/baditaflorin/l"
)

func main() {
    // Use default logger
    l.Info("Hello, World!")
    
    // Log with context
    l.Info("User logged in",
        "user_id", "123",
        "ip", "192.168.1.1",
    )
}

Configuration

Create a custom logger with specific configuration:

config := l.Config{
    Output:      os.Stdout,
    FilePath:    "logs/app.log",
    JsonFormat:  true,
    AsyncWrite:  true,
    BufferSize:  1024 * 1024,      // 1MB buffer
    MaxFileSize: 10 * 1024 * 1024, // 10MB max file size
    MaxBackups:  5,
    AddSource:   true,
    Metrics:     true,
}

factory := l.NewStandardFactory()
logger, err := factory.CreateLogger(config)
if err != nil {
    panic(err)
}
defer logger.Close()

Advanced Usage

Structured Logging with Context
logger := l.With(
    "service", "auth-service",
    "environment", "production",
)

logger.Info("Authentication attempt",
    "user_id", "123",
    "success", true,
    "method", "oauth2",
)
Error Handling
logger.Error("Database connection failed",
    "error", err,
    "retry_count", retries,
    "database", "users",
)
Log Rotation
config := l.Config{
    FilePath:    "logs/app.log",
    MaxFileSize: 10 * 1024 * 1024, // 10MB
    MaxBackups:  5,                // Keep 5 backups
}
Metrics Collection
Metrics, err := factory.CreateMetricsCollector(config)
if err != nil {
    panic(err)
}

// Get Metrics
stats := Metrics.GetMetrics()
fmt.Printf("Total Messages: %d\n", stats.TotalMessages)
fmt.Printf("Error Messages: %d\n", stats.ErrorMessages)
Health Checking
healthChecker, err := factory.CreateHealthChecker(logger)
if err != nil {
    panic(err)
}

healthChecker.Start(context.Background())
defer healthChecker.Stop()

if err := healthChecker.Check(); err != nil {
    logger.Error("Health check failed", "error", err)
}

Examples

The library includes several example applications demonstrating different use cases:

  • Basic logging (example/simple)
  • Web service logging (example/web-service)
  • Audit trail logging (example/audit-trail)
  • High-throughput logging (example/high-throughput)
  • Worker pool logging (example/worker-pool)
  • Metrics dashboard (example/Metrics-dashboard)
  • Error handling (example/error-handling)
  • Log rotation (example/log-rotation)
  • Security logging (example/security-logging)
  • Performance logging (example/performance-logging)
  • Structured logging (example/structured-logging)

Performance

The library is designed for high performance with features like:

  • Asynchronous writing with buffering
  • Batch processing of log messages
  • Efficient JSON encoding
  • Minimal allocations
  • Concurrent-safe operations

Best Practices

  1. Always defer Close():

    logger, err := factory.CreateLogger(config)
    if err != nil {
        panic(err)
    }
    defer logger.Close()
    
  2. Use structured logging:

    // Good
    logger.Info("User action", "user_id", userID, "action", action)
    
    // Avoid
    logger.Info(fmt.Sprintf("User %s performed action %s", userID, action))
    
  3. Include context:

    logger = logger.With(
        "service", serviceName,
        "version", version,
        "environment", env,
    )
    
  4. Handle errors appropriately:

    if err := logger.Flush(); err != nil {
        // Handle error
    }
    

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

Testing

Run the test suite:

./run_coverage.sh

This will run all tests and generate a coverage report in the coverage directory.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Support

For support, please open an issue in the GitHub repository or contact the maintainers.

Documentation

Overview

File: default.go

File: l/fast_middleware.go

Package l provides a structured logging framework with interface-based components

l/middleware.go

l/new_logger.go

Index

Constants

View Source
const (
	LevelDebug = slog.LevelDebug
	LevelInfo  = slog.LevelInfo
	LevelWarn  = slog.LevelWarn
	LevelError = slog.LevelError
)

Predefined log levels.

Variables

View Source
var ErrBufferFull = fmt.Errorf("log buffer full")

Functions

func Debug

func Debug(msg string, args ...any)

func Error

func Error(msg string, args ...any)

func FastLoggingMiddleware added in v1.5.1

func FastLoggingMiddleware(next fasthttp.RequestHandler) fasthttp.RequestHandler

FastLoggingMiddleware returns a fasthttp.RequestHandler middleware that logs incoming requests and their durations using the default logger. When debug-level logging is enabled, it logs additional details such as request headers, query parameters, cookies, and a snippet of the request body, as well as response headers.

func Info

func Info(msg string, args ...any)

Package-level logging functions that use the default logger

func SetDefaultLogger added in v1.2.0

func SetDefaultLogger(logger Logger)

SetDefaultLogger allows users to replace the default logger with their own instance

func Warn

func Warn(msg string, args ...any)

Types

type BatchProcessor added in v1.2.0

type BatchProcessor interface {
	ProcessBatch(records []LogRecord) error
	IsBatchReady() bool
}

BatchProcessor defines batch processing capabilities

type BufferManager added in v1.2.0

type BufferManager interface {
	Write([]byte) (int, error)
	Lifecycle
	Flushable
	IsFull() bool
}

BufferManager handles message buffering operations

type BufferedWriter added in v1.2.0

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

BufferedWriter implements Writer with async buffering

func NewBufferedWriter added in v1.2.0

func NewBufferedWriter(out io.Writer, bufferSize int) *BufferedWriter

func (*BufferedWriter) Close added in v1.2.0

func (w *BufferedWriter) Close() error

func (*BufferedWriter) Flush added in v1.2.0

func (w *BufferedWriter) Flush() error

func (*BufferedWriter) Write added in v1.2.0

func (w *BufferedWriter) Write(p []byte) (n int, err error)

Update the Write method in BufferedWriter to handle large messages better

type Config added in v1.2.0

type Config struct {
	// New fields
	Level       slog.Level // New: minimum log level
	JSON        bool       // New: output JSON? (true means JSON format)
	ServiceName string     // New: service name to include in logs
	Environment string     // New: e.g. "production" or "development"
	TimeFormat  string     // New: timestamp format

	MinLevel      slog.Level
	AddSource     bool
	JsonFormat    bool
	AsyncWrite    bool
	BufferSize    int
	MaxFileSize   int64
	MaxBackups    int
	ErrorCallback func(error)
	Metrics       bool
	Output        io.Writer
	FilePath      string
}

Config holds logger configuration

type Configurable added in v1.2.0

type Configurable interface {
	Configure(config Config) error
	GetConfig() Config
}

Configurable defines configuration management

type ContextProvider added in v1.2.0

type ContextProvider interface {
	WithContext(ctx context.Context) Logger
	GetContext() context.Context
}

ContextProvider defines context management

type DirectWriter added in v1.2.0

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

DirectWriter implements Writer for synchronous writes

func NewDirectWriter added in v1.2.0

func NewDirectWriter(out io.Writer) *DirectWriter

func (*DirectWriter) Close added in v1.2.0

func (w *DirectWriter) Close() error

func (*DirectWriter) Flush added in v1.2.0

func (w *DirectWriter) Flush() error

func (*DirectWriter) Write added in v1.2.0

func (w *DirectWriter) Write(p []byte) (n int, err error)

type Enricher added in v1.2.0

type Enricher interface {
	Enrich(record *LogRecord) error
}

Enricher defines log enrichment capabilities

type ErrorHandler added in v1.2.0

type ErrorHandler interface {
	Handle(error)
	WithRecovery(fn func() error) error
}

ErrorHandler manages error handling and recovery

type Factory added in v1.2.0

type Factory interface {
	CreateLogger(config Config) (Logger, error)
	CreateWriter(config Config) (Writer, error)
	CreateFormatter(config Config) (Formatter, error)
	CreateMetricsCollector(config Config) (MetricsCollector, error)
	CreateRotationManager(config Config) (RotationManager, error)
	CreateErrorHandler(config Config) (ErrorHandler, error)
	CreateBufferManager(config Config) (BufferManager, error)
	CreateHandlerWrapper(handler slog.Handler, closer io.Closer) HandlerWrapper
	CreateHealthChecker(logger Logger) (HealthChecker, error)
}

Factory interface for creating logger components

func NewStandardFactory added in v1.2.0

func NewStandardFactory() Factory

type FieldProvider added in v1.2.0

type FieldProvider interface {
	WithFields(fields map[string]interface{}) Logger
	GetFields() map[string]interface{}
}

FieldProvider defines structured field management

type FileWriter added in v1.2.0

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

FileWriter implements Writer for file-based logging

func NewFileWriter added in v1.2.0

func NewFileWriter(config Config) (*FileWriter, error)

func (*FileWriter) Close added in v1.2.0

func (w *FileWriter) Close() error

func (*FileWriter) Flush added in v1.2.0

func (w *FileWriter) Flush() error

func (*FileWriter) Write added in v1.2.0

func (w *FileWriter) Write(p []byte) (n int, err error)

type FilterFunc added in v1.2.0

type FilterFunc func(LogRecord) bool

FilterFunc defines a function type for log filtering

type Filterable added in v1.2.0

type Filterable interface {
	ShouldLog(record LogRecord) bool
}

Filterable defines log filtering capabilities

type Flushable added in v1.2.0

type Flushable interface {
	Flush() error
}

Flushable defines the flush operation

type Formatter added in v1.2.0

type Formatter interface {
	Format(record LogRecord) ([]byte, error)
	WithOptions(opts FormatterOptions) Formatter
}

Formatter handles log message formatting

type FormatterOptions added in v1.2.0

type FormatterOptions struct {
	TimeFormat string
	UseColor   bool
	Indent     string
}

FormatterOptions defines formatting options

type HandlerWrapper added in v1.2.0

type HandlerWrapper interface {
	slog.Handler
	Lifecycle
}

HandlerWrapper provides a wrapper for slog.Handler with lifecycle management

type HealthChecker added in v1.2.0

type HealthChecker interface {
	Start(context.Context)
	Check() error
	Stop()
}

HealthChecker monitors logger health

type JSONFormatter added in v1.2.0

type JSONFormatter struct{}

Formatters

func NewJSONFormatter added in v1.2.0

func NewJSONFormatter() *JSONFormatter

func (*JSONFormatter) Format added in v1.2.0

func (f *JSONFormatter) Format(record LogRecord) ([]byte, error)

func (*JSONFormatter) WithOptions added in v1.2.0

func (f *JSONFormatter) WithOptions(opts FormatterOptions) Formatter

type Level added in v1.4.2

type Level = slog.Level

Level is an alias for slog.Level.

func ParseLevel added in v1.4.2

func ParseLevel(levelStr string) Level

ParseLevel converts a string (case-insensitive) to the corresponding log Level. Supported values are "debug", "warn", "error"; all others default to LevelInfo.

type Lifecycle added in v1.2.0

type Lifecycle interface {
	Close() error
}

Lifecycle defines common lifecycle methods

type LogRecord added in v1.2.0

type LogRecord struct {
	Level     slog.Level
	Message   string
	Time      time.Time
	Source    string
	Args      []any
	Attrs     []slog.Attr
	Context   context.Context
	AddSource bool
}

LogRecord represents a single log entry

type Logger added in v1.2.0

type Logger interface {
	Info(msg string, args ...any)
	Error(msg string, args ...any)
	Warn(msg string, args ...any)
	Debug(msg string, args ...any)
	With(args ...any) Logger
	WithFields(fields map[string]interface{}) Logger // Add this
	GetFields() map[string]interface{}               // Add this
	Flush() error
	Close() error
	GetContext() context.Context
	WithContext(ctx context.Context) Logger
}

Logger defines the main logging interface

func GetDefaultLogger added in v1.2.0

func GetDefaultLogger() Logger

GetDefaultLogger returns the current default logger instance

func NewLogger added in v1.4.4

func NewLogger(cfg Config) Logger

NewLogger is a convenience function that creates a new logger using the standard factory and the provided configuration. It panics if the logger cannot be created.

func NewStandardLogger added in v1.2.0

func NewStandardLogger(factory Factory, config Config) (Logger, error)

NewStandardLogger creates a new logger instance using the provided factory

func With

func With(args ...any) Logger

With returns a new logger with the given key-value pairs added to the context

type Metrics added in v1.2.0

type Metrics struct {
	TotalMessages   uint64
	ErrorMessages   uint64
	DroppedMessages uint64
	LastError       time.Time
	LastFlush       time.Time
	BufferSize      int
	BufferUsage     float64
}

Metrics holds logger operational Metrics

type MetricsCollector added in v1.2.0

type MetricsCollector interface {
	IncrementTotal()
	IncrementErrors()
	IncrementDropped()
	SetLastError(time.Time)
	SetLastFlush(time.Time)
	GetMetrics() Metrics
	Reset()
}

MetricsCollector handles logging Metrics collection and reporting

type QueryOptions added in v1.2.0

type QueryOptions struct {
	Limit     int
	Offset    int
	StartTime time.Time
	EndTime   time.Time
	OrderBy   string
	Order     string
}

QueryOptions defines options for log querying

type Queryable added in v1.2.0

type Queryable interface {
	Query(filter FilterFunc, opts QueryOptions) ([]LogRecord, error)
}

Queryable defines query capabilities for logs

type RateLimiter added in v1.2.0

type RateLimiter interface {
	Allow() bool
	GetLimit() int
	GetBurst() int
}

RateLimiter defines rate limiting capabilities

type Rotatable added in v1.2.0

type Rotatable interface {
	ShouldRotate() bool
	Rotate() error
}

Rotatable defines rotation capabilities

type RotationManager added in v1.2.0

type RotationManager interface {
	ShouldRotate(size int64) bool
	Rotate() error
	Cleanup() error
	GetCurrentFile() (io.Writer, error)
}

RotationManager handles log file rotation operations

type Sampler added in v1.2.0

type Sampler interface {
	ShouldSample(record LogRecord) bool
	GetSamplingRate() float64
}

Sampler defines sampling capabilities

type StackTraceLine added in v1.4.5

type StackTraceLine struct {
	Function string
	File     string
	Line     int
}

StackTraceLine represents a single line in a stack trace.

type StandardBufferManager added in v1.2.0

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

StandardBufferManager implements BufferManager

func NewStandardBufferManager added in v1.2.0

func NewStandardBufferManager(size int) *StandardBufferManager

func (*StandardBufferManager) Close added in v1.2.0

func (b *StandardBufferManager) Close() error

func (*StandardBufferManager) Flush added in v1.2.0

func (b *StandardBufferManager) Flush() error

func (*StandardBufferManager) IsFull added in v1.2.0

func (b *StandardBufferManager) IsFull() bool

func (*StandardBufferManager) Write added in v1.2.0

func (b *StandardBufferManager) Write(p []byte) (n int, err error)

type StandardErrorHandler added in v1.2.0

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

Error Handler implementation

func NewStandardErrorHandler added in v1.2.0

func NewStandardErrorHandler(callback func(error)) *StandardErrorHandler

func (*StandardErrorHandler) Handle added in v1.2.0

func (h *StandardErrorHandler) Handle(err error)

func (*StandardErrorHandler) WithRecovery added in v1.2.0

func (h *StandardErrorHandler) WithRecovery(fn func() error) (err error)

type StandardFactory added in v1.2.0

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

StandardFactory implements the Factory interface

func (*StandardFactory) CreateBufferManager added in v1.2.0

func (f *StandardFactory) CreateBufferManager(config Config) (BufferManager, error)

func (*StandardFactory) CreateErrorHandler added in v1.2.0

func (f *StandardFactory) CreateErrorHandler(config Config) (ErrorHandler, error)

func (*StandardFactory) CreateFormatter added in v1.2.0

func (f *StandardFactory) CreateFormatter(config Config) (Formatter, error)

func (*StandardFactory) CreateHandlerWrapper added in v1.2.0

func (f *StandardFactory) CreateHandlerWrapper(handler slog.Handler, closer io.Closer) HandlerWrapper

func (*StandardFactory) CreateHealthChecker added in v1.2.0

func (f *StandardFactory) CreateHealthChecker(logger Logger) (HealthChecker, error)

func (*StandardFactory) CreateLogger added in v1.2.0

func (f *StandardFactory) CreateLogger(config Config) (Logger, error)

Modify the CreateLogger method in StandardFactory

func (*StandardFactory) CreateMetricsCollector added in v1.2.0

func (f *StandardFactory) CreateMetricsCollector(config Config) (MetricsCollector, error)

func (*StandardFactory) CreateRotationManager added in v1.2.0

func (f *StandardFactory) CreateRotationManager(config Config) (RotationManager, error)

func (*StandardFactory) CreateWriter added in v1.2.0

func (f *StandardFactory) CreateWriter(config Config) (Writer, error)

type StandardHandlerWrapper added in v1.2.0

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

Handler Wrapper implementation

func NewStandardHandlerWrapper added in v1.2.0

func NewStandardHandlerWrapper(handler slog.Handler, closer io.Closer) *StandardHandlerWrapper

func (*StandardHandlerWrapper) Close added in v1.2.0

func (h *StandardHandlerWrapper) Close() error

func (*StandardHandlerWrapper) Enabled added in v1.2.0

func (h *StandardHandlerWrapper) Enabled(ctx context.Context, level slog.Level) bool

func (*StandardHandlerWrapper) Handle added in v1.2.0

func (*StandardHandlerWrapper) WithAttrs added in v1.2.0

func (h *StandardHandlerWrapper) WithAttrs(attrs []slog.Attr) slog.Handler

func (*StandardHandlerWrapper) WithGroup added in v1.2.0

func (h *StandardHandlerWrapper) WithGroup(name string) slog.Handler

type StandardHealthChecker added in v1.2.0

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

Health Checker implementation

func NewStandardHealthChecker added in v1.2.0

func NewStandardHealthChecker(logger Logger) *StandardHealthChecker

func (*StandardHealthChecker) Check added in v1.2.0

func (h *StandardHealthChecker) Check() error

func (*StandardHealthChecker) Start added in v1.2.0

func (h *StandardHealthChecker) Start(ctx context.Context)

func (*StandardHealthChecker) Stop added in v1.2.0

func (h *StandardHealthChecker) Stop()

type StandardLogger added in v1.2.0

type StandardLogger struct {
	Metrics MetricsCollector
	// contains filtered or unexported fields
}

StandardLogger implements the Logger interface

func (*StandardLogger) Close added in v1.2.0

func (l *StandardLogger) Close() error

func (*StandardLogger) Debug added in v1.2.0

func (l *StandardLogger) Debug(msg string, args ...any)

func (*StandardLogger) Error added in v1.2.0

func (l *StandardLogger) Error(msg string, args ...any)

func (*StandardLogger) Flush added in v1.2.0

func (l *StandardLogger) Flush() error

func (*StandardLogger) GetContext added in v1.2.0

func (l *StandardLogger) GetContext() context.Context

func (*StandardLogger) GetFields added in v1.2.0

func (l *StandardLogger) GetFields() map[string]interface{}

func (*StandardLogger) Info added in v1.2.0

func (l *StandardLogger) Info(msg string, args ...any)

Logger interface implementation

func (*StandardLogger) LogError added in v1.4.5

func (l *StandardLogger) LogError(ctx context.Context, err error)

LogError is a convenience method that logs an error with enhanced context. It simply adds the error (via WithError) and then logs it at error level.

func (*StandardLogger) RecoveryMiddleware added in v1.4.5

func (l *StandardLogger) RecoveryMiddleware() func(http.Handler) http.Handler

RecoveryMiddleware returns middleware that recovers from panics.

func (*StandardLogger) RequestLogger added in v1.4.5

func (l *StandardLogger) RequestLogger() func(http.Handler) http.Handler

RequestLogger returns middleware that logs HTTP requests.

func (*StandardLogger) Warn added in v1.2.0

func (l *StandardLogger) Warn(msg string, args ...any)

func (*StandardLogger) With added in v1.2.0

func (l *StandardLogger) With(args ...any) Logger

func (*StandardLogger) WithContext added in v1.2.0

func (l *StandardLogger) WithContext(ctx context.Context) Logger

Implement ContextProvider interface

func (*StandardLogger) WithError added in v1.4.5

func (l *StandardLogger) WithError(err error) Logger

WithError returns a new logger with the error field added. If the error is nil, it returns the current logger unchanged.

func (*StandardLogger) WithFields added in v1.2.0

func (l *StandardLogger) WithFields(fields map[string]interface{}) Logger

Implement FieldProvider interface

type StandardMetricsCollector added in v1.2.0

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

Metrics implementation

func NewStandardMetricsCollector added in v1.2.0

func NewStandardMetricsCollector() *StandardMetricsCollector

func (*StandardMetricsCollector) GetMetrics added in v1.2.0

func (m *StandardMetricsCollector) GetMetrics() Metrics

func (*StandardMetricsCollector) IncrementDropped added in v1.2.0

func (m *StandardMetricsCollector) IncrementDropped()

func (*StandardMetricsCollector) IncrementErrors added in v1.2.0

func (m *StandardMetricsCollector) IncrementErrors()

func (*StandardMetricsCollector) IncrementTotal added in v1.2.0

func (m *StandardMetricsCollector) IncrementTotal()

func (*StandardMetricsCollector) Reset added in v1.2.0

func (m *StandardMetricsCollector) Reset()

func (*StandardMetricsCollector) SetLastError added in v1.2.0

func (m *StandardMetricsCollector) SetLastError(t time.Time)

func (*StandardMetricsCollector) SetLastFlush added in v1.2.0

func (m *StandardMetricsCollector) SetLastFlush(t time.Time)

type StandardRotationManager added in v1.2.0

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

StandardRotationManager implements RotationManager

func NewStandardRotationManager added in v1.2.0

func NewStandardRotationManager(config Config) *StandardRotationManager

func (*StandardRotationManager) Cleanup added in v1.2.0

func (r *StandardRotationManager) Cleanup() error

func (*StandardRotationManager) GetCurrentFile added in v1.2.0

func (r *StandardRotationManager) GetCurrentFile() (io.Writer, error)

func (*StandardRotationManager) Rotate added in v1.2.0

func (r *StandardRotationManager) Rotate() error

func (*StandardRotationManager) ShouldRotate added in v1.2.0

func (r *StandardRotationManager) ShouldRotate(size int64) bool

type TextFormatter added in v1.2.0

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

func NewTextFormatter added in v1.2.0

func NewTextFormatter() *TextFormatter

func (*TextFormatter) Format added in v1.2.0

func (f *TextFormatter) Format(record LogRecord) ([]byte, error)

func (*TextFormatter) WithOptions added in v1.2.0

func (f *TextFormatter) WithOptions(opts FormatterOptions) Formatter

type Validator added in v1.2.0

type Validator interface {
	Validate() error
}

Validator defines validation capabilities

type Writer added in v1.2.0

type Writer interface {
	io.Writer
	Lifecycle
	Flushable
}

Writer defines the interface for log output handling with lifecycle management

Directories

Path Synopsis
example
custom
File: example/custom/main.go
File: example/custom/main.go
security-logging
File: example/security-logging/main.go
File: example/security-logging/main.go
structured-logging
File: example/structured-logging/main.go
File: example/structured-logging/main.go

Jump to

Keyboard shortcuts

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