From 572c3d517899524c2a7c4c84ad9646660168d4cd Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Mon, 19 Dec 2011 18:41:37 -0800 Subject: * BufferedLogger is deprecated. Use ActiveSupport::Logger, or the logger from Ruby stdlib. --- railties/lib/rails.rb | 1 - railties/lib/rails/application/bootstrap.rb | 8 ++++---- railties/lib/rails/performance_test_help.rb | 2 +- 3 files changed, 5 insertions(+), 6 deletions(-) (limited to 'railties/lib') diff --git a/railties/lib/rails.rb b/railties/lib/rails.rb index 73bdd0b552..04c7415f3f 100644 --- a/railties/lib/rails.rb +++ b/railties/lib/rails.rb @@ -5,7 +5,6 @@ require 'pathname' require 'active_support' require 'active_support/core_ext/kernel/reporting' require 'active_support/core_ext/array/extract_options' -require 'active_support/core_ext/logger' require 'rails/application' require 'rails/version' diff --git a/railties/lib/rails/application/bootstrap.rb b/railties/lib/rails/application/bootstrap.rb index e189009cc5..78d2e6c913 100644 --- a/railties/lib/rails/application/bootstrap.rb +++ b/railties/lib/rails/application/bootstrap.rb @@ -33,13 +33,13 @@ module Rails f.sync = !Rails.env.production? # make sure every write flushes logger = ActiveSupport::TaggedLogging.new( - ActiveSupport::BufferedLogger.new(f) + ActiveSupport::Logger.new(f) ) - logger.level = ActiveSupport::BufferedLogger.const_get(config.log_level.to_s.upcase) + logger.level = ActiveSupport::Logger.const_get(config.log_level.to_s.upcase) logger rescue StandardError - logger = ActiveSupport::TaggedLogging.new(ActiveSupport::BufferedLogger.new(STDERR)) - logger.level = ActiveSupport::BufferedLogger::WARN + logger = ActiveSupport::TaggedLogging.new(ActiveSupport::Logger.new(STDERR)) + logger.level = ActiveSupport::Logger::WARN logger.warn( "Rails Error: Unable to access log file. Please ensure that #{path} exists and is chmod 0666. " + "The log level has been raised to WARN and the output directed to STDERR until the problem is fixed." diff --git a/railties/lib/rails/performance_test_help.rb b/railties/lib/rails/performance_test_help.rb index 4ac38981d0..b1285efde2 100644 --- a/railties/lib/rails/performance_test_help.rb +++ b/railties/lib/rails/performance_test_help.rb @@ -1,3 +1,3 @@ ActionController::Base.perform_caching = true ActiveSupport::Dependencies.mechanism = :require -Rails.logger.level = ActiveSupport::BufferedLogger::INFO +Rails.logger.level = ActiveSupport::Logger::INFO -- cgit v1.2.3