jenkinsci / jenkinsci/subversion-plugin
[JENKINS-9150] Matrix (multi-configuraton) jobs don't work with the SVN emulate clean workspace checkout strategy
- Dominant language
- Java
- Stars
- 131
- Forks
- 275
- Avg merge
- 12h 4m
- Merged PRs (30d)
- 6
Description
When the matrix job runs it will do the "clean" and update for a overall workspace first then do the same for the different configurations. When this happens the different configuration workspaces are deleted and a fresh checkout is done. Since each configuration has its own workspace, I don't think there needs to even be a separate general workspace.
For instance if the workspace/repo has files a, b, c, the file system looks like this for a matrix job for configuration of database=oracle/sql:
jobs/MatrixJob/workspace/a
jobs/MatrixJob/workspace/b
jobs/MatrixJob/workspace/c
jobs/MatrixJob/workspace/database/oracle/a
jobs/MatrixJob/workspace/database/oracle/b
jobs/MatrixJob/workspace/database/oracle/c
jobs/MatrixJob/workspace/database/sqla
jobs/MatrixJob/workspace/database/sql/b
jobs/MatrixJob/workspace/database/sql/c
Since the general workspace is cleaned first, it will delete the database folder since it is a non-versioned file and print a message like:
Cleaning up /home/jenkins/.jenkins/jobs/MatrixJob/workspace/.
Deleting /home/jenkins/.jenkins/jobs/MatrixJob/workspace/./database <= this is not right!
Then in the separate configuration, there will be a fresh checkout instead of a quick "clean" and update:
Checking out a fresh workspace because there's no workspace at /home/jenkins/.jenkins/jobs/MatrixJob/workspace/database/oracle
---
Originally reported by kmart216, imported from: Matrix (multi-configuraton) jobs don't work with the SVN emulate clean workspace checkout strategy
Raw content of original issue
When the matrix job runs it will do the "clean" and update for a overall workspace first then do the same for the different configurations. When this happens the different configuration workspaces are deleted and a fresh checkout is done. Since each configuration has its own workspace, I don't think there needs to even be a separate general workspace.
For instance if the workspace/repo has files a, b, c, the file system looks like this for a matrix job for configuration of database=oracle/sql:
jobs/MatrixJob/workspace/a
jobs/MatrixJob/workspace/b
jobs/MatrixJob/workspace/c
jobs/MatrixJob/workspace/database/oracle/a
jobs/MatrixJob/workspace/database/oracle/b
jobs/MatrixJob/workspace/database/oracle/c
jobs/MatrixJob/workspace/database/sqla
jobs/MatrixJob/workspace/database/sql/b
jobs/MatrixJob/workspace/database/sql/cSince the general workspace is cleaned first, it will delete the database folder since it is a non-versioned file and print a message like:
Cleaning up /home/jenkins/.jenkins/jobs/MatrixJob/workspace/.
Deleting /home/jenkins/.jenkins/jobs/MatrixJob/workspace/./database <= this is not right!Then in the separate configuration, there will be a fresh checkout instead of a quick "clean" and update:
Checking out a fresh workspace because there's no workspace at /home/jenkins/.jenkins/jobs/MatrixJob/workspace/database/oracle
- environment:
Linux, x86, Jenkins 1.401, Subversion 1.24
Contributor guide
Assessment
This issue has not been assessed yet.