@Override
public void service(HttpServletRequest req, HttpServletResponse res)
throws ServletException, IOException {
try {
ErrorMail errorMail = new ErrorMailFactory(ExceptionData.fromRequest(req), env).build();
mailer.register(errorMail);
req.setAttribute("stackTrace", errorMail.getStackTrace());
req.getRequestDispatcher("/WEB-INF/jsp/error/500.jsp").forward(req, res);
} catch (EmailException e) {
logger.error(e.getMessage());