java.util.ConcurrentModificationException

ZK-Tracker | dennis | 4 years ago
  1. 0

    When using SelectorComposer in Tomcat 6 , I tried to simulate the fail-over/didPasssive,active scenario by shutdown/restart tomcat. When using BindComposer and GenericForwardComposer everything is find and page work as expected after access/restart. However, when using SelectorComposer, it causes a ConcurrentModificationException when restart tomcat. and after the restart, the page that uses SelectorComposer cannot run as expected if show exception after 6.0.1 and 6.5.0, although 6.0.0 doesn't shows exception, but it still cannot work as expected. {code} >>java.util.ConcurrentModificationException >> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793) >> at java.util.HashMap$ValueIterator.next(HashMap.java:822) >> at org.zkoss.zk.ui.AbstractComponent.didActivate(AbstractComponent.java:2565) >> at org.zkoss.zk.ui.AbstractComponent.sessionDidActivate(AbstractComponent.java:2521) >> at org.zkoss.zk.ui.impl.PageImpl.sessionDidActivate(PageImpl.java:1021) >> at org.zkoss.zk.ui.impl.DesktopImpl.sessDidActivate(DesktopImpl.java:989) >> at org.zkoss.zk.ui.impl.DesktopImpl.sessionDidActivate(DesktopImpl.java:940) >> at org.zkoss.zk.ui.impl.SimpleDesktopCache.sessionDidActivate(SimpleDesktopCache.java:163) >> at org.zkoss.zk.ui.impl.SessionDesktopCacheProvider.sessionDidActivate(SessionDesktopCacheProvider.java:73) >> at org.zkoss.zk.ui.impl.AbstractWebApp.sessionDidActivate(AbstractWebApp.java:337) >> at org.zkoss.zk.ui.http.SimpleSession$2.didActivate(SimpleSession.java:506) >> at org.zkoss.zk.ui.http.WebManager.<init>(WebManager.java:251) >> at org.zkoss.zk.ui.http.HttpSessionListener23.contextInitialized(HttpSessionListener23.java:140) >> at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4206) >> at org.apache.catalina.core.StandardContext.start(StandardContext.java:4705) >> at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:799) >> at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:779) >> at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:601) >> at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:943) >> at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:778) >> at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:504) >> at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1317) >> at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:324) >> at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:142) >> at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1065) >> at org.apache.catalina.core.StandardHost.start(StandardHost.java:840) >> at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1057) >> at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:463) >> at org.apache.catalina.core.StandardService.start(StandardService.java:525) >> at org.apache.catalina.core.StandardServer.start(StandardServer.java:754) >> at org.apache.catalina.startup.Catalina.start(Catalina.java:595) >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) >> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) >> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) >> at java.lang.reflect.Method.invoke(Method.java:597) >> at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:289) >> at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:414) {code}

    ZK-Tracker | 4 years ago | dennis
    java.util.ConcurrentModificationException
  2. 0

    When using SelectorComposer in Tomcat 6 , I tried to simulate the fail-over/didPasssive,active scenario by shutdown/restart tomcat. When using BindComposer and GenericForwardComposer everything is find and page work as expected after access/restart. However, when using SelectorComposer, it causes a ConcurrentModificationException when restart tomcat. and after the restart, the page that uses SelectorComposer cannot run as expected if show exception after 6.0.1 and 6.5.0, although 6.0.0 doesn't shows exception, but it still cannot work as expected. {code} >>java.util.ConcurrentModificationException >> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793) >> at java.util.HashMap$ValueIterator.next(HashMap.java:822) >> at org.zkoss.zk.ui.AbstractComponent.didActivate(AbstractComponent.java:2565) >> at org.zkoss.zk.ui.AbstractComponent.sessionDidActivate(AbstractComponent.java:2521) >> at org.zkoss.zk.ui.impl.PageImpl.sessionDidActivate(PageImpl.java:1021) >> at org.zkoss.zk.ui.impl.DesktopImpl.sessDidActivate(DesktopImpl.java:989) >> at org.zkoss.zk.ui.impl.DesktopImpl.sessionDidActivate(DesktopImpl.java:940) >> at org.zkoss.zk.ui.impl.SimpleDesktopCache.sessionDidActivate(SimpleDesktopCache.java:163) >> at org.zkoss.zk.ui.impl.SessionDesktopCacheProvider.sessionDidActivate(SessionDesktopCacheProvider.java:73) >> at org.zkoss.zk.ui.impl.AbstractWebApp.sessionDidActivate(AbstractWebApp.java:337) >> at org.zkoss.zk.ui.http.SimpleSession$2.didActivate(SimpleSession.java:506) >> at org.zkoss.zk.ui.http.WebManager.<init>(WebManager.java:251) >> at org.zkoss.zk.ui.http.HttpSessionListener23.contextInitialized(HttpSessionListener23.java:140) >> at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4206) >> at org.apache.catalina.core.StandardContext.start(StandardContext.java:4705) >> at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:799) >> at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:779) >> at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:601) >> at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:943) >> at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:778) >> at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:504) >> at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1317) >> at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:324) >> at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:142) >> at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1065) >> at org.apache.catalina.core.StandardHost.start(StandardHost.java:840) >> at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1057) >> at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:463) >> at org.apache.catalina.core.StandardService.start(StandardService.java:525) >> at org.apache.catalina.core.StandardServer.start(StandardServer.java:754) >> at org.apache.catalina.startup.Catalina.start(Catalina.java:595) >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) >> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) >> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) >> at java.lang.reflect.Method.invoke(Method.java:597) >> at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:289) >> at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:414) {code}

    ZK-Tracker | 4 years ago | dennis
    java.util.ConcurrentModificationException
  3. Speed up your debug routine!

    Automated exception search integrated into your IDE

  4. 0

    ConcurrentModificationException when reading JMS queue mBean on JBoss

    GitHub | 5 years ago | mkuthan
    java.util.ConcurrentModificationException
  5. 0

    Java Concurrency Issue with Iterator and Nested Hashtable

    Stack Overflow | 6 years ago | Bill Spaulding
    java.util.ConcurrentModificationException

    4 unregistered visitors
    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.util.ConcurrentModificationException

      No message provided

      at java.util.HashMap$HashIterator.nextEntry()
    2. Java RT
      HashMap$ValueIterator.next
      1. java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
      2. java.util.HashMap$ValueIterator.next(HashMap.java:822)
      2 frames
    3. ZK Kernel
      HttpSessionListener23.contextInitialized
      1. org.zkoss.zk.ui.AbstractComponent.didActivate(AbstractComponent.java:2565)
      2. org.zkoss.zk.ui.AbstractComponent.sessionDidActivate(AbstractComponent.java:2521)
      3. org.zkoss.zk.ui.impl.PageImpl.sessionDidActivate(PageImpl.java:1021)
      4. org.zkoss.zk.ui.impl.DesktopImpl.sessDidActivate(DesktopImpl.java:989)
      5. org.zkoss.zk.ui.impl.DesktopImpl.sessionDidActivate(DesktopImpl.java:940)
      6. org.zkoss.zk.ui.impl.SimpleDesktopCache.sessionDidActivate(SimpleDesktopCache.java:163)
      7. org.zkoss.zk.ui.impl.SessionDesktopCacheProvider.sessionDidActivate(SessionDesktopCacheProvider.java:73)
      8. org.zkoss.zk.ui.impl.AbstractWebApp.sessionDidActivate(AbstractWebApp.java:337)
      9. org.zkoss.zk.ui.http.SimpleSession$2.didActivate(SimpleSession.java:506)
      10. org.zkoss.zk.ui.http.WebManager.<init>(WebManager.java:251)
      11. org.zkoss.zk.ui.http.HttpSessionListener23.contextInitialized(HttpSessionListener23.java:140)
      11 frames
    4. Glassfish Core
      Catalina.start
      1. org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4206)
      2. org.apache.catalina.core.StandardContext.start(StandardContext.java:4705)
      3. org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:799)
      4. org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:779)
      5. org.apache.catalina.core.StandardHost.addChild(StandardHost.java:601)
      6. org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:943)
      7. org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:778)
      8. org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:504)
      9. org.apache.catalina.startup.HostConfig.start(HostConfig.java:1317)
      10. org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:324)
      11. org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:142)
      12. org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1065)
      13. org.apache.catalina.core.StandardHost.start(StandardHost.java:840)
      14. org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1057)
      15. org.apache.catalina.core.StandardEngine.start(StandardEngine.java:463)
      16. org.apache.catalina.core.StandardService.start(StandardService.java:525)
      17. org.apache.catalina.core.StandardServer.start(StandardServer.java:754)
      18. org.apache.catalina.startup.Catalina.start(Catalina.java:595)
      18 frames
    5. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      4. java.lang.reflect.Method.invoke(Method.java:597)
      4 frames
    6. Glassfish Core
      Bootstrap.main
      1. org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:289)
      2. org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:414)
      2 frames