1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
Commit graph

7 commits

Author SHA1 Message Date
wycats
4aded43b73 Replace the placeholder base_hook API with on_load. To specify some code that
should run during framework load do:

ActiveSupport.on_load(:action_controller) do
  # Code run in the context of AC::Base
end
2010-03-29 17:08:50 -07:00
wycats
39d6f9e112 Make many parts of Rails lazy. In order to facilitate this,
add lazy_load_hooks.rb, which allows us to declare code that
should be run at some later time. For instance, this allows
us to defer requiring ActiveRecord::Base at boot time purely
to apply configuration. Instead, we register a hook that should
apply configuration once ActiveRecord::Base is loaded.

With these changes, brings down total boot time of a
new app to 300ms in production and 400ms in dev.

TODO: rename base_hook
2010-03-07 06:24:30 -08:00
José Valim
226d8e745a Refactor MetalLoader and RoutesReloader to rely less on class configuration.
Signed-off-by: Carl Lerche <carllerche@mac.com>
2010-01-28 10:28:40 -08:00
José Valim
84ebfa4550 Ensure metals and initializers in plugins are loaded. 2010-01-24 14:48:00 +01:00
José Valim
2fde9d774b Solve some pendencies. 2010-01-24 09:32:54 +01:00
José Valim
13d66cdf25 Extract Railtie load from application. 2010-01-23 16:59:37 +01:00
José Valim
80130d1201 Extract routes reloading responsibilities from application and load them just upon a request. 2010-01-23 16:06:33 +01:00