[jboss-jira] [JBoss JIRA] (WFLY-11082) ClassCastExceptions and unexpected ServletContainerInitializer executions
Brian Stansberry (Jira)
issues at jboss.org
Thu Mar 14 21:21:00 EDT 2019
[ https://issues.jboss.org/browse/WFLY-11082?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13708659#comment-13708659 ]
Brian Stansberry commented on WFLY-11082:
-----------------------------------------
"ServiceLoader provide only one instance of SCI"
Looking at the reproducer I see two "createJar()" calls which means two addAsServiceProvider(ServletContainerInitializer.class, SCI.class). Both of those META-INF/services files are visible when the war starts which means two ServiceLoader calls. It doesn't matter that there's only one Impl1.class.
If there's something I missed that means one of the META-INF/services files should not be visible, please let reopen. Otherwise I don't see a bug here.
> ClassCastExceptions and unexpected ServletContainerInitializer executions
> -------------------------------------------------------------------------
>
> Key: WFLY-11082
> URL: https://issues.jboss.org/browse/WFLY-11082
> Project: WildFly
> Issue Type: Bug
> Components: Web (Undertow)
> Affects Versions: 14.0.1.Final
> Reporter: Alexander Kudrevatykh
> Assignee: Bartosz Baranowski
> Priority: Major
> Attachments: dependencies.zip
>
>
> I got unexpected ClassCastExceptions in setup as in attached test
> ServiceLoader provide only one instance of SCI, but wildlfy executes it twice
> More weird - wrong Set of classes passed to onStartup method - classes are not extends @HandlesTypes annotation (because they loaded with different classloaders)
> sorry for complex description, look for attached test
--
This message was sent by Atlassian Jira
(v7.12.1#712002)
More information about the jboss-jira
mailing list