-
Bug
-
Resolution: Done
-
Major
-
27.0.1.Final
-
None
For a couple of versions of Wildfly we have been using javax.mail together with the Default Mail Provider that gets shipped with WF without any issues.
Also, with the release of WF 27.0.0.Final, we used jakarta.mail without any issues.
However, when start up WF 27.0.1.Final, we eventually get the following exception:
org.jboss.msc.service.StartException in service jboss.deployment.unit."Huge.war".WeldStartService: Failed to start service at org.jboss.msc@1.4.13.Final//org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1731) at org.jboss.msc@1.4.13.Final//org.jboss.msc.service.ServiceControllerImpl$ControllerTask.run(ServiceControllerImpl.java:1559) at org.jboss.threads@2.4.0.Final//org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35) at org.jboss.threads@2.4.0.Final//org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1990) at org.jboss.threads@2.4.0.Final//org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1486) at org.jboss.threads@2.4.0.Final//org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1377) at java.base/java.lang.Thread.run(Thread.java:1589) Caused by: java.lang.IllegalStateException: Not provider of jakarta.mail.util.StreamProvider was found at jakarta.mail.api@2.1.1.jbossorg-1//jakarta.mail.util.FactoryFinder.find(FactoryFinder.java:64) at jakarta.mail.api@2.1.1.jbossorg-1//jakarta.mail.util.StreamProvider.provider(StreamProvider.java:186) at jakarta.mail.api@2.1.1.jbossorg-1//jakarta.mail.Session.<init>(Session.java:254) at jakarta.mail.api@2.1.1.jbossorg-1//jakarta.mail.Session.getInstance(Session.java:308) at org.jboss.as.mail@27.0.1.Final//org.jboss.as.mail.extension.SessionProviderFactory$ManagedSession.getSession(SessionProviderFactory.java:171) at org.jboss.as.mail@27.0.1.Final//org.jboss.as.mail.extension.MailSessionService.getValue(MailSessionService.java:73) at org.jboss.as.mail@27.0.1.Final//org.jboss.as.mail.extension.MailSessionManagedReferenceFactory.getReference(MailSessionManagedReferenceFactory.java:56) at org.jboss.as.mail@27.0.1.Final//org.jboss.as.mail.extension.MailSessionManagedReferenceFactory.getInstanceClassName(MailSessionManagedReferenceFactory.java:50) at org.jboss.as.weld.common@27.0.1.Final//org.jboss.as.weld.services.bootstrap.AbstractResourceInjectionServices.validateResourceInjectionPointType(AbstractResourceInjectionServices.java:92) at org.jboss.as.weld@27.0.1.Final//org.jboss.as.weld.services.bootstrap.WeldResourceInjectionServices.registerResourceInjectionPoint(WeldResourceInjectionServices.java:182) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.injection.ResourceInjectionFactory$ResourceResourceInjectionProcessor.getResourceReferenceFactory(ResourceInjectionFactory.java:210) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.injection.ResourceInjectionFactory$ResourceResourceInjectionProcessor.getResourceReferenceFactory(ResourceInjectionFactory.java:203) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.injection.ResourceInjectionProcessor.createFieldResourceInjection(ResourceInjectionProcessor.java:104) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.injection.ResourceInjectionProcessor.createResourceInjections(ResourceInjectionProcessor.java:141) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.injection.ResourceInjectionProcessor.createResourceInjections(ResourceInjectionProcessor.java:94) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.injection.ResourceInjectionFactory.discoverType(ResourceInjectionFactory.java:272) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.injection.ResourceInjectionFactory.getResourceInjections(ResourceInjectionFactory.java:81) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.injection.producer.ResourceInjector.<init>(ResourceInjector.java:59) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.injection.producer.ResourceInjector.of(ResourceInjector.java:48) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.injection.producer.BeanInjectionTarget.<init>(BeanInjectionTarget.java:63) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.injection.producer.BeanInjectionTarget.createDefault(BeanInjectionTarget.java:47) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.manager.InjectionTargetFactoryImpl.chooseInjectionTarget(InjectionTargetFactoryImpl.java:139) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.manager.InjectionTargetFactoryImpl.createInjectionTarget(InjectionTargetFactoryImpl.java:88) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.bean.ManagedBean.<init>(ManagedBean.java:102) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.bean.ManagedBean.of(ManagedBean.java:82) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.bootstrap.AbstractBeanDeployer.createManagedBean(AbstractBeanDeployer.java:275) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.bootstrap.BeanDeployer.createClassBean(BeanDeployer.java:278) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.bootstrap.ConcurrentBeanDeployer$2.doWork(ConcurrentBeanDeployer.java:68) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.bootstrap.ConcurrentBeanDeployer$2.doWork(ConcurrentBeanDeployer.java:65) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.executor.IterativeWorkerTaskFactory$1.call(IterativeWorkerTaskFactory.java:62) at org.jboss.weld.core@5.1.0.Final//org.jboss.weld.executor.IterativeWorkerTaskFactory$1.call(IterativeWorkerTaskFactory.java:55) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642) at java.base/java.lang.Thread.run(Thread.java:1589) at org.jboss.threads@2.4.0.Final//org.jboss.threads.JBossThread.run(JBossThread.java:513)
As a test, we forced WF 27.0.1 to use the module wildfly-mail-27.0.0.Final.jar (e.g. previous version of the mail subsystem), and then everything works 100%
I am not sure if there was any changes in the 27.0.1 version of mail subsystem that could have caused this issue.
- relates to
-
WFLY-19093 Jakarta Mail no longer needs to find implementations on the Thread Context Class Loader
- Closed