Changeset 8787
- Timestamp:
- 02/02/08 20:18:18 (7 months ago)
- Files:
-
- trunk/activerecord/CHANGELOG (modified) (1 diff)
- trunk/activerecord/lib/active_record/observer.rb (modified) (1 diff)
- trunk/railties/CHANGELOG (modified) (1 diff)
- trunk/railties/lib/initializer.rb (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/activerecord/CHANGELOG
r8762 r8787 1 1 *SVN* 2 3 * Add note about how ActiveRecord::Observer classes are initialized in a Rails app. #10980 [fxn] 2 4 3 5 * MySQL: omit text/blob defaults from the schema instead of using an empty string. #10963 [mdeiters] trunk/activerecord/lib/active_record/observer.rb
r8602 r8787 126 126 # Observers will not be invoked unless you define these in your application configuration. 127 127 # 128 # == Loading 129 # 130 # Observers register themselves in the model class they observe, since it is the class that 131 # notifies them of events when they occur. As a side-effect, when an observer is loaded its 132 # corresponding model class is loaded. 133 # 134 # Up to (and including) Rails 2.0.2 observers were instantiated between plugins and 135 # application initializers. Now observers are loaded after application initializers, 136 # so observed models can make use of extensions. 137 # 138 # If by any chance you are using observed models in the initialization you can still 139 # load their observers by calling <tt>ModelObserver.instance</tt> before. Observers are 140 # singletons and that call instantiates and registers them. 141 # 128 142 class Observer 129 143 include Singleton trunk/railties/CHANGELOG
r8772 r8787 1 1 *SVN* 2 3 * Reshuffle load order so that routes and observers are initialized after plugins and app initializers. Closes #10980 [rick] 2 4 3 5 * Git support for script/generate. #10690 [ssoroka] trunk/railties/lib/initializer.rb
r8638 r8787 88 88 load_plugins 89 89 90 # the framework is now fully initialized 91 after_initialize 92 93 load_application_initializers 94 95 # Routing must be initialized after plugins to allow the former to extend the routes 96 initialize_routing 97 90 98 # Observers are loaded after plugins in case Observers or observed models are modified by plugins. 91 99 load_observers 92 93 # Routing must be initialized after plugins to allow the former to extend the routes94 initialize_routing95 96 # the framework is now fully initialized97 after_initialize98 99 load_application_initializers100 100 end 101 101