[FIX] JamesMailSpooler should be more resilient on JVM Error

Upon JVM Error, the error would not be caught to be retried. Therefore, the message would not be acked -> RabbitMQ would disconnect the MailQueue consumer after the Delivery Acknowledgement Timeout.

For example, a custom mailet that depends on the old `javax` APIs caused `java.lang.NoSuchMethodError: 'javax.mail.internet.MimeMessage org.apache.mailet.Mail.getMessage()` that caused the RabbitMQ consumer being disconnected.
1 file changed