-
Notifications
You must be signed in to change notification settings - Fork 55
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
[JENKINS-46028] Use primary job as fallback #26
[JENKINS-46028] Use primary job as fallback #26
Conversation
pom.xml
Outdated
</dependency> | ||
<dependency> | ||
<groupId>org.jenkins-ci.plugins.workflow</groupId> | ||
<artifactId>workflow-multibranch</artifactId> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure if it's such good idea to pull in these additional dependencie. Any way around this? @jglick maybe? Sorry, my first Jenkins contribution.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, luckily most of them (all but branch-api
) are test dependencies only.
We implemented fallback to the master branch in jenkinsci/parallel-test-executor-plugin#26 Until this is merged, we need to use our own fork.
Btw. tests ran here. |
Currently, test results are only taken from the last builds of this job. The result is that the first build(s) of a newly created branch (when using multi- branch jobs) do not run tests in parallel, unless the build for this branch is non-FAILURE. With short-lived feature branches, this results in unsatisfying long build times. In case of multi-branch jobs, other branches could act as a source for test records as well. The question, which branch to use as reference can be answered with the SCM's help - the PrimaryInstanceMetadataAction is assigned by several SCM plugins and denotes one/multiple branches as "primary" (in Git: the default branch when checking out).
e6971eb
to
42d6e3b
Compare
Hey. I've force-pushed a new version with extended tests, as we discovered a side-effect of the last change. References: .hpi, Travis run |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not the right place to be doing this. See JENKINS-33274.
Thanks for your feedback @jglick. I see, it would make a lot more sense to implement the API described in JENKINS-33274. But can you give me an estimation, when this API will be available in Jenkins and the Git SCM plugin? I mean, the issue is 18 months old.. It would be really nice to have a solution for the problem of non-parallel first builds (already now). That's why I went down the path to pick the most reasonable branch based on the Once JENKINS-33274 is merged, this plugin could still be adjusted to do it even better, right? |
I do not know if it is planned for development.
But then this plugin would be stuck with a stale option. |
as nothing happened on JENKINS-33274 in the meantime, I'm asking myself how to proceed with this. I'm willing to spend some time on this PR, if you provide me some guidance how to improve the implementation -- and in general comment if you see this feature within the scope of this plugin. In case you don't think this is a worthy feature, I probably go ahead and maintain an own version.
Thanks for your feedback. |
Taken over in #226. |
Currently, test results are only taken from the last builds of this job. The result is that the first build(s) of a newly created branch (when using multi-branch jobs) do not run tests in parallel, unless the build for this branch is non-FAILURE. With short-lived feature branches, this results in unsatisfying long build times.
In case of multi-branch jobs, other branches could act as a source for test records as well. The question, which branch to use as reference can be answered with the SCM's help - the
PrimaryInstanceMetadataAction
is assigned by several SCM plugins and denotes one/multiple branches as "primary" (in Git: the default branch when checking out).