quantranhong1999 commented on code in PR #3072:
URL: https://github.com/apache/james-project/pull/3072#discussion_r3489263285
##########
server/container/guice/protocols/smtp/src/main/java/org/apache/james/modules/protocols/SmtpGuiceProbe.java:
##########
@@ -56,6 +57,12 @@ private SmtpGuiceProbe(SMTPServerFactory smtpServerFactory) {
this.smtpServerFactory = smtpServerFactory;
}
+ @PreDestroy
+ void destroy() {
+ // SMTPServerFactory is provided through a factory method; dispose it
explicitly on Guice shutdown.
+ smtpServerFactory.destroy();
+ }
Review Comment:
Fix JMX issue (instance already existed) when running some SMTP tests e.g.
`MemoryTeamMailboxSmtpTest`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]