So I deduced from Rack documentation, but maybe I am wrong...
It sure is. You can write rack middleware to add additional routing handlers before the request hits the rails application.
http://guides.rubyonrails.org/rails_on_rack.html
In addition, you can also run "rake middleware" to view the currently installed rack modules.