This does not work very well with Plack
where exit 0 is not a good idea
exit 0
because it kills the Plack server