Catching and handling any exceptions that occur during handling of requests.