Class: EventHub::LoggerProxy

Inherits:
Object
  • Object
show all
Defined in:
lib/eventhub/logger.rb

Overview

Logger proxy that automatically includes correlation_id in structured log output

Instance Method Summary collapse

Constructor Details

#initialize(logger) ⇒ LoggerProxy

Returns a new instance of LoggerProxy.



5
6
7
# File 'lib/eventhub/logger.rb', line 5

def initialize(logger)
  @logger = logger
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method, *args, &block) ⇒ Object



25
26
27
# File 'lib/eventhub/logger.rb', line 25

def method_missing(method, *args, &block)
  @logger.send(method, *args, &block)
end

Instance Method Details

#respond_to_missing?(method, include_private = false) ⇒ Boolean

Returns:

  • (Boolean)


29
30
31
# File 'lib/eventhub/logger.rb', line 29

def respond_to_missing?(method, include_private = false)
  @logger.respond_to?(method, include_private)
end