Method deprecated or moved
This method is deprecated or moved on the latest stable version.
The last existing version (v1.2.6) is shown here.
These similar methods exist in v3.2.13:
dispatch(cgi = nil, session_options = ActionController::CgiRequest::DEFAULT_SESSION_OPTIONS, output = $stdout)
public
Dispatch the given CGI request, using the given
session options, and emitting the output via the given output. If you dispatch with your own CGI object be sure to handle the exceptions it raises
on multipart requests (EOFError and ArgumentError).
Show source
def dispatch(cgi = nil, session_options = ActionController::CgiRequest::DEFAULT_SESSION_OPTIONS, output = $stdout)
controller = nil
if cgi ||= new_cgi(output)
request, response = ActionController::CgiRequest.new(cgi, session_options), ActionController::CgiResponse.new(cgi)
prepare_application
controller = ActionController::Routing::Routes.recognize(request)
controller.process(request, response).out(output)
end
rescue Exception => exception
failsafe_response(output, '500 Internal Server Error', exception) do
controller ||= (ApplicationController rescue ActionController::Base)
controller.process_with_exception(request, response, exception).out(output)
end
ensure
reset_after_dispatch
end