Frage

I'm using Logback's SMTPAppender to send e-mails when certain logging events occur on my Tomcat.

The SMTPAppender can send e-mails asynchronously. Then however shutting down Tomcat fails because Tomcat can't close SMTPAppender's thread pool.

Is it somehow possible to close this thread pool when Tomcat is shutting down?

War es hilfreich?

Lösung 2

Andere Tipps

if you're using Tomcat, it seems that configuring Logback's Tomcat valve should resolve this issue for you:

http://logback.qos.ch/access.html

Configuring the Valve will result in Tomcat automatically shutting down the associated ExecutorService upon shutdown.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top