[jboss-osgi-issues] [JBoss JIRA] (JBOSGI-805) ConcurrentModificationException from AbstractWiring when loading a dynamically imported class

Hannu Lahtinen (JIRA) issues at jboss.org
Fri Nov 18 09:29:00 EST 2016


    [ https://issues.jboss.org/browse/JBOSGI-805?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13324911#comment-13324911 ] 

Hannu Lahtinen commented on JBOSGI-805:
---------------------------------------

I had a hard time reproducing the bug with the old version, so my testing is not complete. I can tell you I reproduced it only once in ~20 boot ups with the old version and 0 times in 3 boots with the new version.  I reviewed your changes and I don't see any reason why it wouldn't fix this. I will test further on Monday and try to make a test case so I can hopefully reproduce it more consistently.

> ConcurrentModificationException from AbstractWiring when loading a dynamically imported class
> ---------------------------------------------------------------------------------------------
>
>                 Key: JBOSGI-805
>                 URL: https://issues.jboss.org/browse/JBOSGI-805
>             Project: JBoss OSGi
>          Issue Type: Bug
>          Components: framework, resolver
>    Affects Versions: JBossOSGI 2.5.2
>            Reporter: Hannu Lahtinen
>            Assignee: Arcadiy Ivanov
>             Fix For: JBossOSGI 2.5.3
>
>
> {code}
> java.util ConcurrentModificationException
> at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:901) [rt.jar:1.8.0_102]
> at java.util.ArrayList$Itr.next(ArrayList.java:851) [rt.jar:1.8.0_102]
> at org.jboss.osgi.resolver.spi.AbstractWiring.addProvidedWire(AbstractWiring.java:120)
> at org.jboss.osgi.framework.internal.FallbackLoader.loadClassLocal (FallbackLoader.java:165)
> at org.jboss.modules.Module.loadModuleClass(Module.java:613) [jboss-modules.jar:1.5.1.Final]
> at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:190) [jboss-modules.jar:1.5.1.Final]
> at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:363) [jboss-modules.jar:1.5.1.Final]
> at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:351) [jboss-modules.jar:1.5.1.Final]
> at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:93) [jboss-modules.jar:1.5.1.Final]
> ...
> {code}
> Steps that cause the exception to occur:
> 1. bundle with DIP: * in MANIFEST.
> 2. 2 different threads call above mentioned bundle with the same class that needs to be imported dynamically.
> This exception is timing based and does not happen every time but in our environment happens about 20% of the time.



--
This message was sent by Atlassian JIRA
(v7.2.3#72005)


More information about the jboss-osgi-issues mailing list