diff options
author | Joshua Peek <josh@joshpeek.com> | 2009-10-14 19:50:06 -0500 |
---|---|---|
committer | Joshua Peek <josh@joshpeek.com> | 2009-10-14 19:50:36 -0500 |
commit | 8cbf825425dc8ad3770881ea4e100b9023c69ce2 (patch) | |
tree | 560e40df6aa1e888df3fe88ff4c87e1cb3b27e0e /activesupport/lib | |
parent | bf9819f73d74e19052b7b8a7a9885972a27e8876 (diff) | |
download | rails-8cbf825425dc8ad3770881ea4e100b9023c69ce2.tar.gz rails-8cbf825425dc8ad3770881ea4e100b9023c69ce2.tar.bz2 rails-8cbf825425dc8ad3770881ea4e100b9023c69ce2.zip |
Rename Orchestra to Notifications [#3321 state:resolved]
Diffstat (limited to 'activesupport/lib')
-rw-r--r-- | activesupport/lib/active_support/autoload.rb | 2 | ||||
-rw-r--r-- | activesupport/lib/active_support/cache.rb | 2 | ||||
-rw-r--r-- | activesupport/lib/active_support/notifications.rb (renamed from activesupport/lib/active_support/orchestra.rb) | 16 |
3 files changed, 10 insertions, 10 deletions
diff --git a/activesupport/lib/active_support/autoload.rb b/activesupport/lib/active_support/autoload.rb index f3a68b482f..2b5ebcf390 100644 --- a/activesupport/lib/active_support/autoload.rb +++ b/activesupport/lib/active_support/autoload.rb @@ -18,7 +18,7 @@ module ActiveSupport autoload :MessageVerifier, 'active_support/message_verifier' autoload :Multibyte, 'active_support/multibyte' autoload :OptionMerger, 'active_support/option_merger' - autoload :Orchestra, 'active_support/orchestra' + autoload :Notifications, 'active_support/notifications' autoload :OrderedHash, 'active_support/ordered_hash' autoload :OrderedOptions, 'active_support/ordered_options' autoload :Rescuable, 'active_support/rescuable' diff --git a/activesupport/lib/active_support/cache.rb b/activesupport/lib/active_support/cache.rb index a415686020..e0f671f283 100644 --- a/activesupport/lib/active_support/cache.rb +++ b/activesupport/lib/active_support/cache.rb @@ -247,7 +247,7 @@ module ActiveSupport payload = { :key => key } payload.merge!(options) if options.is_a?(Hash) - event = ActiveSupport::Orchestra.instrument(:"cache_#{operation}", payload, &block) + event = ActiveSupport::Notifications.instrument(:"cache_#{operation}", payload, &block) log("#{operation} (%.1fms)" % event.duration, key, options) event.result end diff --git a/activesupport/lib/active_support/orchestra.rb b/activesupport/lib/active_support/notifications.rb index efe30669d8..6335686196 100644 --- a/activesupport/lib/active_support/orchestra.rb +++ b/activesupport/lib/active_support/notifications.rb @@ -1,10 +1,10 @@ require 'thread' module ActiveSupport - # Orchestra provides an instrumentation API for Ruby. To instrument an action + # Notifications provides an instrumentation API for Ruby. To instrument an action # in Ruby you just need to: # - # ActiveSupport::Orchestra.instrument(:render, :extra => :information) do + # ActiveSupport::Notifications.instrument(:render, :extra => :information) do # render :text => "Foo" # end # @@ -12,23 +12,23 @@ module ActiveSupport # to push. You can even register an array: # # @listener = [] - # ActiveSupport::Orchestra.register @listener + # ActiveSupport::Notifications.register @listener # - # ActiveSupport::Orchestra.instrument(:render, :extra => :information) do + # ActiveSupport::Notifications.instrument(:render, :extra => :information) do # render :text => "Foo" # end # - # event #=> ActiveSupport::Orchestra::Event + # event #=> ActiveSupport::Notifications::Event # event.name #=> :render # event.duration #=> 10 (in miliseconds) # event.result #=> "Foo" # event.payload #=> { :extra => :information } # - # Orchestra ships with a default listener implementation which puts events in + # Notifications ships with a default listener implementation which puts events in # a stream and consume them in a Thread. This implementation is thread safe - # and is available at ActiveSupport::Orchestra::Listener. + # and is available at ActiveSupport::Notifications::Listener. # - module Orchestra + module Notifications @stacked_events = Hash.new { |h,k| h[k] = [] } @listeners = [] |