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

Restore Windows CI runs #6024

Merged
merged 1 commit into from
Dec 21, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,24 @@ properties([
disableConcurrentBuilds(abortPrevious: true)
])

// TODO: Restore 'Windows' once https://groups.google.com/forum/#!topic/jenkinsci-dev/v9d-XosOp2s is resolved
def buildTypes = ['Linux']
def buildTypes = ['Linux', 'Windows']
def jdks = [8, 11]

def builds = [:]
for(i = 0; i < buildTypes.size(); i++) {
for(j = 0; j < jdks.size(); j++) {
def buildType = buildTypes[i]
def jdk = jdks[j]
if (buildType == 'Windows' && jdk == 8) {
continue // unnecessary use of hardware
}
builds["${buildType}-jdk${jdk}"] = {
// see https://github.com/jenkins-infra/documentation/blob/master/ci.adoc#node-labels for information on what node types are available
node(buildType == 'Linux' ? (jdk == 8 ? 'maven' : 'maven-11') : buildType.toLowerCase()) {
String agentContainerLabel = jdk == 8 ? 'maven' : 'maven-11'
if (buildType == 'Windows') {
agentContainerLabel += '-windows'
Copy link
Member

Choose a reason for hiding this comment

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

Do we really need four combinations? To save resources, and sometimes wall clock time, I think it would suffice to run, say, Linux builds on Java 11 and Windows builds on Java 8.

Copy link
Member Author

Choose a reason for hiding this comment

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

Nah, I was planning to reduce this to two runs before marking this change as ready for review. But in the meantime I've been running the draft PR with 4 builds to shake out any flakiness.

BTW #6029

Copy link
Member

Choose a reason for hiding this comment

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

before marking this change as ready for review

#6024 (comment) ?

Copy link
Member Author

Choose a reason for hiding this comment

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

My bad. I marked this as draft.

}
node(agentContainerLabel) {
// First stage is actually checking out the source. Since we're using Multibranch
// currently, we can use "checkout scm".
stage('Checkout') {
Expand Down