Module: ZK::Logger
- Included in:
- Client::Threaded, Election::Base, EventHandler, EventHandlerSubscription::Base, ForkHook, ZK::Locker::LockerBase, NodeDeletionWatcher, Pool::Base, Subscription::Base, ThreadedCallback, Threadpool
- Defined in:
- lib/zk/logger.rb
Overview
use the ZK.logger if non-nil (to allow users to override the logger) otherwise, use a Loggging logger based on the class name
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.wrapped_logger ⇒ Object
5 6 7 8 9 10 11 |
# File 'lib/zk/logger.rb', line 5 def self.wrapped_logger if defined?(@@wrapped_logger) @@wrapped_logger else @@wrapped_logger = ::Logger.new(STDERR).tap { |l| l.level = ::Logger::FATAL } end end |
.wrapped_logger=(log) ⇒ Object
13 14 15 |
# File 'lib/zk/logger.rb', line 13 def self.wrapped_logger=(log) @@wrapped_logger = log end |