spumko/hapi — pull request #1378 by nlf (2014-02-01 00:22:10+00:00)
Title: add failureResponse option to proxy handler

I added this to provide the ability to add route-specific failure handlers, rather than catching them in the onPreResponse event and having to dig through the path to figure out what the original request even was.

This should make it a lot simpler to respond appropriately if an upstream server is down in a caching proxy (as in, respond with a cached copy rather than letting the error through to the client)