You do not need to do this in every method.
You should not catch an exception that cannot be handled. Processing means more than just reorganizing or logging or printing a stack trace. I believe that processing means implementing a meaningful recovery strategy.
This may mean that the โdollar stops hereโ: you are Gandalf on the bridge at the edge of the layer boundary, and no exception will fail. You do not want users to see unpleasant messages, so you catch them and send them to a familiar, easily understood page that tells them what to do next.
Lastly, this is not always necessary, but it is ideal for cleaning up resources such as file descriptors and database cursors.
If you cannot handle the exception, there is no shame in adding a throws clause to the method signature and letting callers figure out what they want to do.
source share