Wow, that's a very nice solution. Thanks :))

-- Edvin

Sebastiaan van Erk skrev:
I would say that the standard practice is probably to use your logging subsystem to email you the exception.

For example, if you are using log4j to log, you could add something like this to your log4j.xml file:

    <appender name="ERRORMAILER"
        class="org.apache.log4j.net.SMTPAppender">
        <param name="from" value="[EMAIL PROTECTED]" />
        <param name="to" value="[EMAIL PROTECTED]" />
        <param name="subject" value="[mydomain] ERROR" />
        <param name="SMTPHost" value="localhost" />
        <param name="threshold" value="ERROR" />
        <layout class="org.apache.log4j.PatternLayout">
<param name="ConversionPattern" value="%d %-5p - [%C:%L] %m%n" />
        </layout>
    </appender>

Regards,
Sebastiaan


Edvin Syse wrote:
Hi. In my application I do:

        getApplicationSettings().setInternalErrorPage(ErrorPage.class);
getExceptionSettings().setUnexpectedExceptionDisplay(IExceptionSettings.SHOW_INTERNAL_ERROR_PAGE);

to display a custom page for error messages. I would also like to email myself the exception - is it possible that I can get a hold of the throwable from the ErrorPage.class, or do I have to explicitly catch and rethrow a RestartResponseException to obtain the exception?

-- Edvin



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to