instance method
preload_frameworks
Ruby on Rails 2.3.18
Since v2.3.18 Last seen in v2.3.18Signature
preload_frameworks()
Preload all frameworks specified by the Configuration#frameworks. Used by Passenger to ensure everything’s loaded before forking and to avoid autoload race conditions in JRuby.
Source
# File railties/lib/initializer.rb, line 277
def preload_frameworks
if configuration.preload_frameworks
configuration.frameworks.each do |framework|
# String#classify and #constantize aren't available yet.
toplevel = Object.const_get(framework.to_s.gsub(/(?:^|_)(.)/) { $1.upcase })
toplevel.load_all! if toplevel.respond_to?(:load_all!)
end
end
end
Defined in railties/lib/initializer.rb line 277
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in Rails::Initializer