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

Matrix build checks out to root workspace directory

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • git-plugin

      When using a matrix build job, the git plugin checks out the repository for each axis combination, which is totally fine.
      Unfortunately, it does also checkout the repository in the root workspace directory.

      Example:

      • Matrix build:
        • CONFBRANCH: master, foo
        • CONFBAR: bar, baz
      • this results in the following combinations:
        • master/bar
        • master/baz
        • foo/bar
        • foo/baz
      • building the project does 5 checkouts:
        • workspace/
        • workspace/CONFBAR/bar/CONFBRANCH/master
        • workspace/CONFBAR/bar/CONFBRANCH/foo
        • workspace/CONFBAR/baz/CONFBRANCH/master
        • workspace/CONFBAR/baz/CONFBRANCH/foo

      In my eyes, the first checkout (to workspace/) should not happen since it does not belong to any matrix build configuration.

          [JENKINS-12008] Matrix build checks out to root workspace directory

          I can confirm this behavior. In my case, since the repository is really huge for legacy reasons, the clone made by the flyweight executor really seems to be a waste.

          Is this clone really necessary?

          Gregory Pakosz added a comment - I can confirm this behavior. In my case, since the repository is really huge for legacy reasons, the clone made by the flyweight executor really seems to be a waste. Is this clone really necessary?

          Matrix "head" has to detect SCM changes, so need a workspace - until we find some way for git plugin to poll without workspace

          Nicolas De Loof added a comment - Matrix "head" has to detect SCM changes, so need a workspace - until we find some way for git plugin to poll without workspace

          Or Shachar added a comment -

          @Nicolas - today we can poll without workspace... so why not implement that solution here. Cloning to root workspace can be quite expensive and redundant...

          Or Shachar added a comment - @Nicolas - today we can poll without workspace... so why not implement that solution here. Cloning to root workspace can be quite expensive and redundant...

          Or Shachar added a comment -

          Today we can poll without workspace... (Remote poll), So why not implement that solution here. Cloning to root workspace can be quite expensive and redundant...

          Or Shachar added a comment - Today we can poll without workspace... (Remote poll), So why not implement that solution here. Cloning to root workspace can be quite expensive and redundant...

            Unassigned Unassigned
            cweiske_nr Christian Weiske
            Votes:
            3 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated: