[Mongrel] custom error handling

Kevin Williams kevwil at gmail.com
Sat Sep 2 10:26:47 EDT 2006

Please forgive me if this is a stupid question. If it has been
answered already, please point me to the answer, as my searching has
been fruitless.

How can I programatically handle 404s and 500s when using Mongrel?
I've read about using a proxy server config (.htaccess for example) to
render an ErrorDocument rather than whatever comes from Rails, but I
need something different. I would like to send an email on 500 errors,
and log 40x errors. It would be nice to do this within my app code.

I ask here simply because everything I've found has dealt with either
plain html pages or FCGI.

Thanks in advance!



"Any sufficiently advanced technology is indistinguishable from
Magic." - Arthur C. Clarke

More information about the Mongrel-users mailing list