[JIRA] (JENKINS-39768) Multiple checkout in Pipeline but only one seen in git data

2 views
Skip to first unread message

roidelapluie@inuits.eu (JIRA)

unread,
Nov 16, 2016, 3:15:01 AM11/16/16
to jenkinsc...@googlegroups.com
Julien Pivotto created an issue
 
Jenkins / Bug JENKINS-39768
Multiple checkout in Pipeline but only one seen in git data
Issue Type: Bug Bug
Assignee: Mark Waite
Attachments: multiscm3.png, multiscm4.png, multiscm5.png
Components: git-plugin, pipeline, workflow-scm-step-plugin
Created: 2016/Nov/16 8:14 AM
Priority: Major Major
Reporter: Julien Pivotto

When using multiple SCM, only one is seen in "git data"; only one is seen in the pipeline stage view as well.

See screenshots.

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

roidelapluie@inuits.eu (JIRA)

unread,
Nov 16, 2016, 3:17:02 AM11/16/16
to jenkinsc...@googlegroups.com
Julien Pivotto commented on Bug JENKINS-39768
 
Re: Multiple checkout in Pipeline but only one seen in git data

There shoild be commits in all the builds; only 9.2-jenkins2-177 has commits in the first repo. Other build have commits in other repositories; that is not shown.

Shows that we have multiple repositories.

Clicking on any repo points to that page. Always about the first repo.

roidelapluie@inuits.eu (JIRA)

unread,
Nov 16, 2016, 3:18:01 AM11/16/16
to jenkinsc...@googlegroups.com
Julien Pivotto edited a comment on Bug JENKINS-39768
!multiscm3.png|thumbnail! There shoild should be commits in all the builds; only 9.2-jenkins2-177 has commits in the first repo. Other build have commits in other repositories; that is not shown.

!multiscm4.png|thumbnail! Shows that we have multiple repositories.


!multiscm5.png|thumbnail! Clicking on any repo points to that page. Always about the first repo.

mark.earl.waite@gmail.com (JIRA)

unread,
Nov 16, 2016, 6:19:02 AM11/16/16
to jenkinsc...@googlegroups.com
Mark Waite assigned an issue to Unassigned
 
Change By: Mark Waite
Assignee: Mark Waite

mark.earl.waite@gmail.com (JIRA)

unread,
Nov 16, 2016, 6:23:02 AM11/16/16
to jenkinsc...@googlegroups.com
Mark Waite commented on Bug JENKINS-39768
 
Re: Multiple checkout in Pipeline but only one seen in git data

Please provide more detailed instructions that will allow others to duplicate the problem on a separate machine. The pictures are certainly helpful, but there are many ways that I could make mistakes or make poor guesses on how you arrived at those pictures.

Best would be a pointer to a Dockerfile or a public Docker instance which will show the problem, since then that can be installed and run and used for diagnosis.

If that's not feasible, then please provide a numbered series of steps which state how to recreate the problem.

roidelapluie@inuits.eu (JIRA)

unread,
Nov 16, 2016, 6:49:02 AM11/16/16
to jenkinsc...@googlegroups.com

Shell script:

cd /tmp; git init foo;(cd foo; touch a; git add a; git commit -m a); for i in 0; do cp -r foo foo$i;(cd foo$i; git commit --amend -m a); done

Pipeline:

stage('test'){
    node {
        checkouts = [:]
        for (i=0; i<10; i++) {
            def x = i
            checkouts["foo${x}"] = {
                checkout([$class: 'GitSCM', branches: [[name: '*/master']],
                doGenerateSubmoduleConfigurations: false, extensions:
                [[$class: 'RelativeTargetDirectory', relativeTargetDir: "foo${x}"],
                [$class: 'ScmName', name: "foo${x}"]],
                submoduleCfg: [], userRemoteConfigs: [[url: "/tmp/foo${x}"]]])
           }
        }
        parallel checkouts 
    }
}

roidelapluie@inuits.eu (JIRA)

unread,
Nov 16, 2016, 6:50:01 AM11/16/16
to jenkinsc...@googlegroups.com
Julien Pivotto edited a comment on Bug JENKINS-39768
Shell script:

{code}
cd /tmp; git init foo;(cd foo; touch a; git add a; git commit -m a); for i in
$(seq 0 30) ; do cp -r foo foo$i;(cd foo$i; git commit --amend -m a); done
{code}


Pipeline:

{code}

stage('test'){
    node {
        checkouts = [:]
        for (i=0; i< 10 30 ; i++) {

            def x = i
            checkouts["foo${x}"] = {
                checkout([$class: 'GitSCM', branches: [[name: '*/master']],
                doGenerateSubmoduleConfigurations: false, extensions:
                [[$class: 'RelativeTargetDirectory', relativeTargetDir: "foo${x}"],
                [$class: 'ScmName', name: "foo${x}"]],
                submoduleCfg: [], userRemoteConfigs: [[url: "/tmp/foo${x}"]]])
           }
        }
        parallel checkouts
    }
}
{code}

roidelapluie@inuits.eu (JIRA)

unread,
Nov 16, 2016, 6:51:01 AM11/16/16
to jenkinsc...@googlegroups.com

jglick@cloudbees.com (JIRA)

unread,
Feb 27, 2017, 1:24:01 PM2/27/17
to jenkinsc...@googlegroups.com
Jesse Glick updated an issue
 
Change By: Jesse Glick
Component/s: pipeline
Component/s: workflow-scm-step-plugin
Labels: pipeline

mark.earl.waite@gmail.com (JIRA)

unread,
Feb 25, 2019, 8:46:04 AM2/25/19
to jenkinsc...@googlegroups.com
Mark Waite updated Bug JENKINS-39768
 

The Pipeline script as included in the bug report is performing checkout to the same directory multiple times. Thus, it looks (to me) like it is doing the same thing multiple times.

If multiple checkouts are needed, then they need to be a separate directories using either the dir or ws pipeline steps.

Change By: Mark Waite
Status: Open Fixed but Unreleased
Resolution: Not A Defect
This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)

mark.earl.waite@gmail.com (JIRA)

unread,
Jan 8, 2020, 7:02:04 AM1/8/20
to jenkinsc...@googlegroups.com
Change By: Mark Waite
Status: Fixed but Unreleased Closed
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo
Reply all
Reply to author
Forward
0 new messages