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

trottle-concurrent-build-plugin allowes concureent jobs under circumstances

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major

      Assume one project triggered parts of triggered by different upstream projects:

      freebsd-all

      • freebsd-checkout-source
      • freebsd-checkout-ports
      • freebsd-makeindex
      • freebsd-portversion
      • freebsd-buildworld
      • freebsd-buildkernel
      • freebsd-installkernel
      • reboot
      • freebsd-installworld
      • reboot
      • freebsd-portupgrade
      • reboot
      • freebsd-testsuite

      freebsd-ports

      • freebsd-checkout-ports
      • freebsd-makeindex
      • freebsd-portversion
      • freebsd-portupgrade
      • reboot
      • freebsd-testsuite

      now lets trigger freebsd-all if scm changes in the source tree are detected, and lets trigger freebsd-ports if sm changes in the ports tree are detected. Since both builds share some downstream builders it is necessary to block freebsd-all if freebsd-ports is running and to block freebsd-ports if freebsd-all is running. To achieve it I'd defined token freebsd.
      Now freebsd-all sets token freebsd -> blocking itself and freebsd-ports if it is running.
      Same for freebsd-ports: sets token freebsd -> blocking itself and freebsd-all.

      If you now trigger both at the very same time, both will acquire token freebsd and both jobs will run in parallel messing up some things – or at least doing them twice!

      Looks like locking implemented by trottle-concurrent-builds leads to a race condition allowing both builds to acquire the same token and both think its all OK to run now.

            Unassigned Unassigned
            tps800 Thomas Schweikle
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: