Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-22553

Listing plugins shortly after installation throws ConcurrentModificationException

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • core
    • None
    • 1.532 LTS, 1.554

      Steps to reproduce: install multiple plugins on /pluginManager/availabale and load /pluginManager/installed while installation is in progress. Often seen running acceptance-tests.

      PluginManager exposes modifiable plugin list that is fed to j:forEach tag. List is being updated by pending plugin installations while the jelly tag is using its iterator.

      javax.servlet.ServletException: org.apache.commons.jelly.JellyTagException: jar:file:${JENKINS_HOME}/war/WEB-INF/lib/jenkins-core-1.532.2.jar!/hudson/PluginManager/installed.jelly:50:69: <j:forEach> java.util.ConcurrentModificationException
       at org.kohsuke.stapler.jelly.JellyFacet$1.dispatch(JellyFacet.java:103)
       at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:728)
       at org.kohsuke.stapler.Stapler.invoke(Stapler.java:858)
       at org.kohsuke.stapler.MetaClass$3.doDispatch(MetaClass.java:182)
       at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:53)
       at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:728)
       at org.kohsuke.stapler.Stapler.invoke(Stapler.java:858)
       at org.kohsuke.stapler.Stapler.invoke(Stapler.java:631)
       at org.kohsuke.stapler.Stapler.service(Stapler.java:225)
       at javax.servlet.http.HttpServlet.service(HttpServlet.java:45)
       at winstone.ServletConfiguration.execute(ServletConfiguration.java:248)
       at winstone.RequestDispatcher.forward(RequestDispatcher.java:333)
       at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:376)
       at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:96)
       at hudson.util.PluginServletFilter.doFilter(PluginServletFilter.java:88)
       at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
       at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
       at hudson.security.csrf.CrumbFilter.doFilter(CrumbFilter.java:48)
       at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
       at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
       at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:84)
       at hudson.security.ChainedServletFilter.doFilter(ChainedServletFilter.java:76)
       at hudson.security.HudsonFilter.doFilter(HudsonFilter.java:164)
       at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
       at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
       at org.kohsuke.stapler.compression.CompressionFilter.doFilter(CompressionFilter.java:46)
       at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
       at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
       at hudson.util.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:81)
       at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
       at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
       at winstone.RequestDispatcher.forward(RequestDispatcher.java:331)
       at winstone.RequestHandlerThread.processRequest(RequestHandlerThread.java:227)
       at winstone.RequestHandlerThread.run(RequestHandlerThread.java:150)
       at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
       at java.util.concurrent.FutureTask.run(FutureTask.java:262)
       at winstone.BoundedExecutorService$1.run(BoundedExecutorService.java:77)
       at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
       at java.lang.Thread.run(Thread.java:744)
      Caused by: org.apache.commons.jelly.JellyTagException: jar:file:${JENKINS_HOME}/war/WEB-INF/lib/jenkins-core-1.532.2.jar!/hudson/PluginManager/installed.jelly:50:69: <j:forEach> java.util.ConcurrentModificationException
       at org.apache.commons.jelly.impl.TagScript.handleException(TagScript.java:726)
       at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:281)
       at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
       at org.apache.commons.jelly.TagSupport.invokeBody(TagSupport.java:161)
       at org.apache.commons.jelly.tags.core.OtherwiseTag.doTag(OtherwiseTag.java:41)
       at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:269)
       at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
       at org.apache.commons.jelly.TagSupport.invokeBody(TagSupport.java:161)
       at org.apache.commons.jelly.tags.core.ChooseTag.doTag(ChooseTag.java:38)
       at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:269)
       at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
       at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
       at org.kohsuke.stapler.jelly.CallTagLibScript$1.run(CallTagLibScript.java:99)
       at org.apache.commons.jelly.tags.define.InvokeBodyTag.doTag(InvokeBodyTag.java:91)
       at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:269)
       at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
       at org.apache.commons.jelly.tags.core.CoreTagLibrary$1.run(CoreTagLibrary.java:98)
       at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
       at org.apache.commons.jelly.tags.core.CoreTagLibrary$2.run(CoreTagLibrary.java:105)
       at org.kohsuke.stapler.jelly.CallTagLibScript.run(CallTagLibScript.java:120)
       at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
       at org.kohsuke.stapler.jelly.CallTagLibScript$1.run(CallTagLibScript.java:99)
       at org.apache.commons.jelly.tags.define.InvokeBodyTag.doTag(InvokeBodyTag.java:91)
       at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:269)
       at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
       at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
       at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
       at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
       at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
       at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
       at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
       at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
       at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
       at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
       at org.apache.commons.jelly.tags.core.CoreTagLibrary$2.run(CoreTagLibrary.java:105)
       at org.kohsuke.stapler.jelly.CallTagLibScript.run(CallTagLibScript.java:120)
       at org.apache.commons.jelly.tags.core.CoreTagLibrary$2.run(CoreTagLibrary.java:105)
       at org.kohsuke.stapler.jelly.JellyViewScript.run(JellyViewScript.java:81)
       at org.kohsuke.stapler.jelly.DefaultScriptInvoker.invokeScript(DefaultScriptInvoker.java:63)
       at org.kohsuke.stapler.jelly.DefaultScriptInvoker.invokeScript(DefaultScriptInvoker.java:53)
       at org.kohsuke.stapler.jelly.JellyFacet$1.dispatch(JellyFacet.java:95)
       ... 39 more
      Caused by: java.util.ConcurrentModificationException
       at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:859)
       at java.util.ArrayList$Itr.next(ArrayList.java:831)
       at org.apache.commons.jelly.tags.core.ForEachTag.doTag(ForEachTag.java:115)
       at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:269)
      

            olivergondza Oliver Gondža
            olivergondza Oliver Gondža
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: