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

[gerrit-trigger] ConcurrentModificationException when loading dynamic triggers

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • gerrit-trigger-plugin
    • None
    • Jenkins 2.346.2, gerrit-trigger 2.36.0, numerous others.
    • Fixed in Gerrit Trigger Plugin 2.36.1

      We get this error in the logs every 30 seconds (slightly edited for anonymity):

      Jul 19 14:05:32 jenkins[5876]: 2022-07-19 12:05:32.057+0000 [id=182] INFO c.s.h.p.g.t.h.DynamicConfigurationCacheProxy#fetchThroughCache: Get dynamic projects directly for URL: http://builder/triggers/jobA/triggers.txt
      Jul 19 14:05:32 jenkins[5876]: 2022-07-19 12:05:32.084+0000 [id=44] INFO c.s.h.p.g.t.h.DynamicConfigurationCacheProxy#fetchThroughCache: Get dynamic projects directly for URL: http://builder/triggers/jobB/triggers-build.txt
      Jul 19 14:05:32 jenkins[5876]: 2022-07-19 12:05:32.094+0000 [id=40] SEVERE hudson.triggers.SafeTimerTask#run: Timer task GerritTriggerTimerTask{job='gerrit-report-barrier'} failed
      Jul 19 14:05:32 jenkins[5876]: java.util.ConcurrentModificationException
      Jul 19 14:05:32 jenkins[5876]:  at java.base/java.util.HashMap$HashIterator.nextNode(HashMap.java:1511)
      Jul 19 14:05:32 jenkins[5876]:  at java.base/java.util.HashMap$KeyIterator.next(HashMap.java:1534)
      Jul 19 14:05:32 jenkins[5876]:  at com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.DynamicConfigurationCacheProxy.fetchThroughCache(DynamicConfigurationCacheProxy.java:44)
      Jul 19 14:05:32 jenkins[5876]:  at com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.GerritTrigger.updateTriggerConfigURL(GerritTrigger.java:1931)
      Jul 19 14:05:32 jenkins[5876]:  at com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.GerritTriggerTimerTask.doRun(GerritTriggerTimerTask.java:63)
      Jul 19 14:05:32 jenkins[5876]:  at hudson.triggers.SafeTimerTask.run(SafeTimerTask.java:92)
      Jul 19 14:05:32 jenkins[5876]:  at jenkins.security.ImpersonatingScheduledExecutorService$1.run(ImpersonatingScheduledExecutorService.java:67)
      Jul 19 14:05:32 jenkins[5876]:  at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
      Jul 19 14:05:32 jenkins[5876]:  at java.base/java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305)
      Jul 19 14:05:32 jenkins[5876]:  at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305)
      Jul 19 14:05:32 jenkins[5876]:  at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
      Jul 19 14:05:32 jenkins[5876]:  at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
      Jul 19 14:05:32 jenkins[5876]:  at java.base/java.lang.Thread.run(Thread.java:829)
      Jul 19 14:05:32 jenkins[5876]: 2022-07-19 12:05:32.094+0000 [id=42] INFO c.s.h.p.g.t.h.DynamicConfigurationCacheProxy#fetchThroughCache: Get dynamic projects directly for URL: http://builder/triggers/jobA/triggers-build.txt

      We have a number of jobs using four different dynamic triggers. There are three different URLs mentioned here, but sometimes it's just one, and sometimes all four are loaded successfully.

      Previously (older versions) we would see that the plug-in just stopped loading the triggers, but now we at least see these error messages. It looks like some threads could be stepping over each other?

            rsandell rsandell
            pharman Torben Thellefsen
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: