tags:

views:

16

answers:

1

I like to use log4j smtp appender and i doubt is it effect to my application memory when it's tries to send too many emails.And where errors located (memory or other) before send? If application crashes then do i lost any "Errors" that not send yet?

A: 

If you are concerned with memory then investigate with e.g. "jvisualvm" in the JDK.

The contents of the mail and the events needed to generate it are stored in memory. I encourage you to investigate the source code.

If your application exits the JVM no more actions can be taken, but mails with errors should have been sent immediately. If this is a concern to you, then consider adding shutdown hooks to be run when the JVM is shutting down.

Thorbjørn Ravn Andersen