I've written some middleware for rack-contrib that add an "X-Runtime"
header with the runtime of the application. Can also set it more than
once, with different suffixes, like this:
use Rack::Runtime, "All"
# use more middlewares here
use Rack::Runtime, "App"
run Application
will set "X-Runtime-All" and "X-Runtime-App" headers on the response.
I sent a pull request to "rack", but I'm not sure who else has commit
rights to the repo.
Here's the branch:
http://github.com/paul/rack-contrib/tree/runtime
Thanks,
Paul