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

Jenkins hangs on circular dependency


    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • ivy-plugin
    • None

      We are using jenkins with ivy, ant and mercurial. I will describe a simplified scenario that reproduces this problem:
      Assume you have 2 repos named repo_a and repo_b. And assume there are 2 ivy modules in repo_a called module_a1 and module_a2. And there is only one module in repo_b called module_b3. There are 2 jobs in jenkins, one per repo called job_a and job_b.

      In ivy here are the module dependencies:
      job_a has two submodules
      job_a >> module_a1
      job_a >> module_a2
      and job_b has one submodule:
      job_b >> module_b3
      As far as ivy is concerned there is no circular dependencies and it is able to build everything without any issue. However in jenkins you can only create jobs at the repo level. So as far as jenkins is concerned there is a circular dependency between job_a and job_b.

      The behaviour I am observing is that jenkins builds job_b and then adds job_b>>module_b3 to the queue. At this point it doesn't take module_b3 off the queue and gives the following reason: "Upstream module job_b is already building". This in effect causes a hang.

      I am not sure there is an easy fix for this. However at the very least the hang should be avoided in some way possibly with a failure somewhere along the line.

      Jenkins ver. 1.626
      Ivy plugin version 1.24
      Mercurial plugin version 1.54

            tbingaman Timothy Bingaman
            nikolaymetchev Nikolay Metchev
            1 Vote for this issue
            2 Start watching this issue