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

Block up-/downstream Projects of matrix projects

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Component/s: matrix-project-plugin
    • Labels:
      None
    • Environment:
      Platform: All, OS: All
    • Similar Issues:

      Description

      As implemented according to issue #1938 for maven builds, it should be possible
      to block up-/downstream project in matrix builds too.

      As a description, my problem:

      We have matrix projects a b c and d. They build a dependency chain a-b-c-d.
      At the time, if the projects changes the builds will start parallel and b,c and
      d don't have the proper results of the upstream projects and fail.
      If a is ready, b is scheduled and so on, the builds all are started again.

      On the other side, if d is running and a changes a have to wait until d (or b or
      c) is ready. At the time it will be started in parallel and probably the other
      projects fail while loosing its dependencies.

      Proposal:

      Matrix builds should have a flag to be able to block the execution of a project
      if an other project in the up-/downstream chain is running.

      If the blocking project has finished, the Queue should be reordered according to
      the up-/downstream chain and the projects should be build according to its
      dependencies. (already queued projects should wait until they are triggered from
      upstream project, or deleted from queue as they are started by the upstream
      project again)

      The parallel build of the axes should not be blocked.

      BTW, this is NOT a duplicate of issue #1938, because matrix projects don't
      support the blocking, like maven projects do, in using hudson version 1.335

        Attachments

          Activity

          Hide
          mbaker000 mbaker000 added a comment -

          I agree with this one, particularly with upstream jobs. We have a build hierarchy where the later jobs need access to an artifact generated in a job higher in the job hierarchy. The issue is that these later jobs take a while to run, and if one of the higher level jobs changes that artifact, using the lastSuccessfulBuild permalink doesn't work.

          Show
          mbaker000 mbaker000 added a comment - I agree with this one, particularly with upstream jobs. We have a build hierarchy where the later jobs need access to an artifact generated in a job higher in the job hierarchy. The issue is that these later jobs take a while to run, and if one of the higher level jobs changes that artifact, using the lastSuccessfulBuild permalink doesn't work.
          Hide
          cjo9900 cjo9900 added a comment -

          Created a patch for this, with the latest release we should be able to just use the default handling for downstream blocking.
          Added config option for this to matrix config properties.

          Tested cases to make sure that it blocks correctly when a downstream job is running.

          Pull request
          https://github.com/jenkinsci/jenkins/pull/178

          Show
          cjo9900 cjo9900 added a comment - Created a patch for this, with the latest release we should be able to just use the default handling for downstream blocking. Added config option for this to matrix config properties. Tested cases to make sure that it blocks correctly when a downstream job is running. Pull request https://github.com/jenkinsci/jenkins/pull/178
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: cjo9900
          Path:
          changelog.html
          core/src/main/resources/hudson/matrix/MatrixProject/configure-entries.jelly
          http://jenkins-ci.org/commit/jenkins/591cbfd113cae53dd19c7c07119e97172fce6310
          Log:
          [FIXED JENKINS-4959] Add Downstream blocking for matrix projects.

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: cjo9900 Path: changelog.html core/src/main/resources/hudson/matrix/MatrixProject/configure-entries.jelly http://jenkins-ci.org/commit/jenkins/591cbfd113cae53dd19c7c07119e97172fce6310 Log: [FIXED JENKINS-4959] Add Downstream blocking for matrix projects.
          Hide
          dogfood dogfood added a comment -
          Show
          dogfood dogfood added a comment - Integrated in jenkins_main_trunk #914
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: cjo9900
          Path:
          changelog.html
          core/src/main/resources/hudson/matrix/MatrixProject/configure-entries.jelly
          http://jenkins-ci.org/commit/jenkins/591cbfd113cae53dd19c7c07119e97172fce6310
          Log:
          [FIXED JENKINS-4959] Add Downstream blocking for matrix projects.

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: cjo9900 Path: changelog.html core/src/main/resources/hudson/matrix/MatrixProject/configure-entries.jelly http://jenkins-ci.org/commit/jenkins/591cbfd113cae53dd19c7c07119e97172fce6310 Log: [FIXED JENKINS-4959] Add Downstream blocking for matrix projects.
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: cjo9900
          Path:
          changelog.html
          core/src/main/resources/hudson/matrix/MatrixProject/configure-entries.jelly
          http://jenkins-ci.org/commit/jenkins/591cbfd113cae53dd19c7c07119e97172fce6310
          Log:
          [FIXED JENKINS-4959] Add Downstream blocking for matrix projects.

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: cjo9900 Path: changelog.html core/src/main/resources/hudson/matrix/MatrixProject/configure-entries.jelly http://jenkins-ci.org/commit/jenkins/591cbfd113cae53dd19c7c07119e97172fce6310 Log: [FIXED JENKINS-4959] Add Downstream blocking for matrix projects.
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: cjo9900
          Path:
          core/src/main/resources/hudson/matrix/MatrixProject/configure-entries.jelly
          http://jenkins-ci.org/commit/matrix-project-plugin/afdeb3440c7c9e06e58d2825fd8292cfd8deb024
          Log:
          [FIXED JENKINS-4959] Add Downstream blocking for matrix projects.

          Originally-Committed-As: 591cbfd113cae53dd19c7c07119e97172fce6310

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: cjo9900 Path: core/src/main/resources/hudson/matrix/MatrixProject/configure-entries.jelly http://jenkins-ci.org/commit/matrix-project-plugin/afdeb3440c7c9e06e58d2825fd8292cfd8deb024 Log: [FIXED JENKINS-4959] Add Downstream blocking for matrix projects. Originally-Committed-As: 591cbfd113cae53dd19c7c07119e97172fce6310

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            wohauser wohauser
            Votes:
            2 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: