Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set Branch Specifier as parameter #4585

Merged
merged 1 commit into from
May 24, 2023
Merged

Set Branch Specifier as parameter #4585

merged 1 commit into from
May 24, 2023

Conversation

llxia
Copy link
Contributor

@llxia llxia commented May 19, 2023

  • If LIGHT_WEIGHT_CHECKOUT=true, set Repository URL explicitly and set Branch Specifier as parameter
  • If LIGHT_WEIGHT_CHECKOUT=false, set both Repository URL and Branch Specifier as parameter

Once https://issues.jenkins.io/browse/JENKINS-42971 is fully resolved, we should remove LIGHT_WEIGHT_CHECKOUT parameter as LIGHT_WEIGHT_CHECKOUT=true should always be set.

resolves: #4580

Signed-off-by: Lan Xia [email protected]

@llxia
Copy link
Contributor Author

llxia commented May 19, 2023

  • With LIGHT_WEIGHT_CHECKOUT = true,

image

00:00:04.765   > git fetch --tags --force --progress -- https://github.com/adoptium/aqa-tests.git +refs/heads/*:refs/remotes/origin/* # timeout=10
00:00:11.092  Avoid second fetch
00:00:11.127  Checking out Revision fb359ab82b182af5c22653f83dc498a900852082 (origin/v0.9.7-release)
00:00:11.039   > git config remote.origin.url https://github.com/adoptium/aqa-tests.git # timeout=10
00:00:11.042   > git config --add remote.origin.fetch +refs/heads/*:refs/remotes/origin/* # timeout=10
00:00:11.109   > git rev-parse origin/v0.9.7-release^{commit} # timeout=10
00:00:11.144   > git config core.sparsecheckout # timeout=10
00:00:11.150   > git checkout -f fb359ab82b182af5c22653f83dc498a900852082 # timeout=1010

@llxia
Copy link
Contributor Author

llxia commented May 19, 2023

  • With LIGHT_WEIGHT_CHECKOUT = false,

image

00:00:11.916   > git fetch --tags --progress -- https://github.com/llxia/openjdk-tests.git +refs/heads/*:refs/remotes/origin/* # timeout=10
00:00:14.691  Avoid second fetch
00:00:14.751  Checking out Revision f39a410f5c3684dd3b01b442297e8b07b2de5027 (origin/test2)
00:00:14.599   > git config remote.origin.url https://github.com/llxia/openjdk-tests.git # timeout=10
00:00:14.606   > git config --add remote.origin.fetch +refs/heads/*:refs/remotes/origin/* # timeout=10
00:00:14.719   > git rev-parse origin/test2^{commit} # timeout=10
00:00:14.778   > git config core.sparsecheckout # timeout=10
00:00:14.785   > git checkout -f f39a410f5c3684dd3b01b442297e8b07b2de5027 # timeout=10

- If LIGHT_WEIGHT_CHECKOUT=true, set Repository URL explicitly and set Branch Specifier as parameter
- If LIGHT_WEIGHT_CHECKOUT=false, set both Repository URL and Branch Specifier as parameter

Once https://issues.jenkins.io/browse/JENKINS-42971 is fully resolved, we should remove LIGHT_WEIGHT_CHECKOUT parameter
as LIGHT_WEIGHT_CHECKOUT=true should always be set.

resolves: adoptium#4580

Signed-off-by: Lan Xia <[email protected]>
@llxia llxia marked this pull request as ready for review May 19, 2023 19:39
@llxia llxia requested review from smlambert and LongyuZhang May 19, 2023 19:40
Copy link
Contributor

@LongyuZhang LongyuZhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

@renfeiw renfeiw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Jenkins Generator: Allow lightweight checkout option
3 participants