Module: DNSResolver::Logger

Included in:
Resolver
Defined in:
lib/dnsresolver/logger.rb

Instance Method Summary collapse

Instance Method Details

#loggerObject



4
5
6
7
8
9
10
11
12
# File 'lib/dnsresolver/logger.rb', line 4

def logger
  unless @logger
    @logger = ::Logger.new(STDOUT)
    @logger.level = ::Logger::INFO
    Celluloid.logger = @logger
  end

  @logger
end

#logger=(logger) ⇒ Object



14
15
16
17
# File 'lib/dnsresolver/logger.rb', line 14

def logger=(logger)
  @logger = logger
  Celluloid.logger = @logger
end