[jboss-jira] [JBoss JIRA] (WFLY-11411) ModuleClassLoader fails with ClassNotFoundException when class in a jar file

Karl Nicholas (Jira) issues at jboss.org
Fri Nov 23 12:06:00 EST 2018


     [ https://issues.jboss.org/browse/WFLY-11411?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Karl Nicholas updated WFLY-11411:
---------------------------------
    Steps to Reproduce: 
Eg.

See attached files. Put "server" in war project and "service" in different jar project.




  was:
Eg.

See attached files.






> ModuleClassLoader fails with ClassNotFoundException when class in a jar file
> ----------------------------------------------------------------------------
>
>                 Key: WFLY-11411
>                 URL: https://issues.jboss.org/browse/WFLY-11411
>             Project: WildFly
>          Issue Type: Bug
>          Components: Class Loading
>    Affects Versions: 11.0.0.Final, 14.0.0.Final
>         Environment: Wildfly 11, 14, Java 1.8, Windows 10
>            Reporter: Karl Nicholas
>            Priority: Major
>         Attachments: JaxRsActivator.java, RestSever.java
>
>
> Simple REST service with Application activator in project and Rest Server in another project with jar file fails to load. 
> Works okay with EAR project structure but not with simpler WAR project structure.
> Caused by: java.lang.ClassNotFoundException: rest.service.server.RestSever from [Module "deployment.restserver7.war" from Service Module Loader]
> 	at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:198)
> 	at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:412)
> 	at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:400)
> 	at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:116)



--
This message was sent by Atlassian Jira
(v7.12.1#712002)


More information about the jboss-jira mailing list