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

Stages running in different agents checkout different versions

    Details

    • Similar Issues:

      Description

      Given a pipeline with multiple stages and some stages running on different agents, if a new commit is push while the pipeline is running, a stage running later in a different agent will implicitly checkout the new commit instead of the commit that originated the pipeline execution.

       

      Steps to reproduce:

      1. Using this repo https://github.com/nicopaez/ejemplo create a pipeline job
      2. Start the pipeline, it will wait for you input after stage 1
      3. Commit+push a change in the repository
      4. Let the pipeline proceed with the execution

      Expected behavior: both stages get the same git commit
      Actual behavior: both stages are getting different git commits

       

      I think the issues is in the implicit checkout operations that is perform on each stage. It seems it is checking out the branch when it should checkout the specific commits that was checkout when the pipeline was started.

       

      We verified this issues on 2 different configurations:

      • A single instance Jenkins setup using docker agents
      • A master-slave Jenkins setup using different server nodes (no docker)

        Attachments

          Activity

          There are no comments yet on this issue.

            People

            • Assignee:
              Unassigned
              Reporter:
              nicopaez Nicolas Paez
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: