2008/1/22, sayoyo Sayoyo
<rails-mailing-list-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org>:
> Does anyone know when exactly the "controller" objects are
> created in rails?
> when the http server starts? or when it is answering a http request?
The dispatcher will handle each request and a new controller
is instantiated by the routing system when a route is recognized.
In ActionController::Dispatcher, you''ve got this method :
def handle_request
@controller = Routing::Routes.recognize(@request)
@controller.process(@request, @response).out(@output)
end
-- Jean-François.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---