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

Handler hang with 100% cpu usage with schedule

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • core
    • None
    • jenkins 2.5
      jenkins 1.651.1
      jenkins 1.651.3

      When I create an scheduled job for the 31 of May some jenkins handler hangs with 100% cpu usage.

      Steps to reproduce:

      • Create a new item
      • Select free style project
      • Select build trigger periodically and set up the schedule for 31th of May. f.e.:
        1 1 31 5 *
      • Add a build step that execs a shell for example with a echo hello
      • save

      Now each time you try to configure this job jenkins process eats up +100%cpu:
      {{ PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
      27568 jenkins 20 0 8577136 1.429g 26588 S 299.9 9.7 27:26.65 java }}

      I forces some thread dumps sending kill signal to jenkins, this is the hanged handler:
      Dump:
      "Handling GET /job/test-schedule/descriptorByName/hudson.triggers.TimerTrigger/checkSpec from 91.126.32.51 : RequestHa
      ndlerThread13" daemon prio=10 tid=0x00007f4adc005800 nid=0x6bf5 runnable [0x00007f4a8af7a000]
      java.lang.Thread.State: RUNNABLE
      at java.util.GregorianCalendar.computeFields(GregorianCalendar.java:2248)
      at java.util.Calendar.setTimeInMillis(Calendar.java:1140)
      at java.util.GregorianCalendar.add(GregorianCalendar.java:1044)
      at hudson.scheduler.CronTab$CalendarField.addTo(CronTab.java:203)
      at hudson.scheduler.CronTab.floor(CronTab.java:401)
      at hudson.scheduler.CronTabList.previous(CronTabList.java:134)
      at hudson.triggers.TimerTrigger$DescriptorImpl.updateValidationsForNextRun(TimerTrigger.java:107)
      at hudson.triggers.TimerTrigger$DescriptorImpl.doCheckSpec(TimerTrigger.java:92)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

      Another from the very same thread:
      "Handling GET /job/test-schedule/descriptorByName/hudson.triggers.TimerTrigger/checkSpec from 91.126.32.51 : RequestHa
      ndlerThread13" daemon prio=10 tid=0x00007f4adc005800 nid=0x6bf5 runnable [0x00007f4a8af7a000]
      java.lang.Thread.State: RUNNABLE
      at sun.util.calendar.ZoneInfo.getTransitionIndex(ZoneInfo.java:351)
      at sun.util.calendar.ZoneInfo.getOffsets(ZoneInfo.java:271)
      at sun.util.calendar.ZoneInfo.getOffsets(ZoneInfo.java:248)
      at java.util.GregorianCalendar.computeFields(GregorianCalendar.java:2276)
      at java.util.GregorianCalendar.computeFields(GregorianCalendar.java:2248)
      at java.util.Calendar.setTimeInMillis(Calendar.java:1140)
      at java.util.GregorianCalendar.add(GregorianCalendar.java:1044)
      at hudson.scheduler.CronTab$CalendarField.addTo(CronTab.java:203)
      at hudson.scheduler.CronTab.floor(CronTab.java:401)

      Request any other further information needed.

      EDIT:
      The timezone configured is Europe/Madrid using JAVA_ARGS:
      -Duser.timezone=Europe/Madrid
      -Dorg.apache.commons.jelly.tags.fmt.timeZone=Europe/Madrid

            anderl86 Andreas K
            nagodar Jose Luis Ledesma
            Votes:
            4 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated: