Exception in JEE application Email Notification Pattern
- by Build Monkey
We have spring 3.0.x based application, we use SimpleMappingExceptionResolver which sends emails on an exception, when the exception happens within the DispatcherServlet.
This gives us following flexibility:
Subject can include who the logged in user is, so that we can send personalized email to the user
Subject also includes the server on which the error occurred
The request params, request url, and headers -- helped us find some problems when search engine indexing the site.
However, lately we have been finding the exceptions have been occurring in the filters, and since this is not going through the Resolver, we dont get any emails.
We dont like the log4j email appender solution, and not writing another filter to send emails seems right.
Is there an accepted pattern to resolve this issue