added code for email notification of exceptions stacktrace