summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBruce Forstall <brucefo@microsoft.com>2018-01-03 16:26:47 -0800
committerGitHub <noreply@github.com>2018-01-03 16:26:47 -0800
commitec76b8a2df66a5ddfcd5cc373221a6d32a73dbd3 (patch)
treeabec25c4487b54dfc1d6822057554ba8bb78706b
parent8b008aa05ab3572edf8946b95cf3b1fe2a4a2cdc (diff)
parentf1c2c62f28185ab2e789d62bc153988de039b6da (diff)
downloadcoreclr-ec76b8a2df66a5ddfcd5cc373221a6d32a73dbd3.tar.gz
coreclr-ec76b8a2df66a5ddfcd5cc373221a6d32a73dbd3.tar.bz2
coreclr-ec76b8a2df66a5ddfcd5cc373221a6d32a73dbd3.zip
Merge pull request #15614 from BruceForstall/AddPushPeriodicViews
Add more Views to Jenkins UI
-rwxr-xr-xnetci.groovy182
1 files changed, 159 insertions, 23 deletions
diff --git a/netci.groovy b/netci.groovy
index aeee8bddd9..321d267f10 100755
--- a/netci.groovy
+++ b/netci.groovy
@@ -254,6 +254,137 @@ class Constants {
def static architectureList = ['arm', 'armlb', 'x86_arm_altjit', 'x64_arm64_altjit', 'arm64', 'x64', 'x86']
}
+// **************************************************************
+// Create some specific views
+//
+// These aren't using the Utilities.addStandardFolderView() function, because that creates
+// views based on a single regular expression. These views will be generated by adding a
+// specific set of jobs to them.
+//
+// Utilities.addStandardFolderView() also creates a lot of additional stuff around the
+// view, like "Build Statistics", "Job Statistics", "Unstable Jobs". Until it is determined
+// those are required, don't add them (which simplifies the view pages, as well).
+// **************************************************************
+
+class Views {
+ def static MergeJobView = null
+ def static PeriodicJobView = null
+ def static ArchitectureViews = [:]
+ def static OSViews = [:]
+}
+
+// MergeJobView: include all jobs that execute when a PR change is merged.
+Views.MergeJobView = listView('Merge') {
+ recurse()
+ columns {
+ status()
+ weather()
+ name()
+ lastSuccess()
+ lastFailure()
+ lastDuration()
+ buildButton()
+ }
+}
+
+// PeriodicJobView: include all jobs that execute on a schedule
+Views.PeriodicJobView = listView('Periodic') {
+ recurse()
+ columns {
+ status()
+ weather()
+ name()
+ lastSuccess()
+ lastFailure()
+ lastDuration()
+ buildButton()
+ }
+}
+
+// Create a view for non-PR jobs for each architecture.
+Constants.architectureList.each { architecture ->
+ Views.ArchitectureViews[architecture] = listView(architecture) {
+ recurse()
+ columns {
+ status()
+ weather()
+ name()
+ lastSuccess()
+ lastFailure()
+ lastDuration()
+ buildButton()
+ }
+ }
+}
+
+// Create a view for non-PR jobs for each OS.
+Constants.osList.each { os ->
+ // Don't create one for the special 'Windows_NT_BuildOnly'
+ if (os == 'Windows_NT_BuildOnly') {
+ return
+ }
+ Views.OSViews[os] = listView(os) {
+ recurse()
+ columns {
+ status()
+ weather()
+ name()
+ lastSuccess()
+ lastFailure()
+ lastDuration()
+ buildButton()
+ }
+ }
+}
+
+def static addToMergeView(def job) {
+ Views.MergeJobView.with {
+ jobs {
+ name(job.name)
+ }
+ }
+}
+
+def static addToPeriodicView(def job) {
+ Views.PeriodicJobView.with {
+ jobs {
+ name(job.name)
+ }
+ }
+}
+
+def static addToViews(def job, def isPR, def architecture, def os) {
+ if (isPR) {
+ // No views want PR jobs currently.
+ return
+ }
+
+ // Add to architecture view.
+ Views.ArchitectureViews[architecture].with {
+ jobs {
+ name(job.name)
+ }
+ }
+
+ // Add to OS view.
+ Views.OSViews[os].with {
+ jobs {
+ name(job.name)
+ }
+ }
+}
+
+def static addPeriodicTriggerHelper(def job, String cronString, boolean alwaysRuns = false) {
+ addToPeriodicView(job)
+ Utilities.addPeriodicTrigger(job, cronString, alwaysRuns)
+}
+
+def static addGithubPushTriggerHelper(def job) {
+ addToMergeView(job)
+ Utilities.addGithubPushTrigger(job)
+}
+
+
def static setMachineAffinity(def job, def os, def architecture, def options = null) {
assert os instanceof String
assert architecture instanceof String
@@ -687,21 +818,21 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
case 'x64':
case 'x86':
if (isFlowJob && architecture == 'x86' && os == 'Ubuntu') {
- Utilities.addPeriodicTrigger(job, '@daily')
+ addPeriodicTriggerHelper(job, '@daily')
}
else if (isFlowJob || os == 'Windows_NT' || !(os in Constants.crossList)) {
- Utilities.addGithubPushTrigger(job)
+ addGithubPushTriggerHelper(job)
}
break
case 'arm':
case 'armlb':
case 'x86_arm_altjit':
case 'x64_arm64_altjit':
- Utilities.addGithubPushTrigger(job)
+ addGithubPushTriggerHelper(job)
break
case 'arm64':
// We would normally want a per-push trigger, but with limited hardware we can't keep up
- Utilities.addPeriodicTrigger(job, "H H/4 * * *")
+ addPeriodicTriggerHelper(job, "H H/4 * * *")
break
default:
println("Unknown architecture: ${architecture}");
@@ -717,24 +848,24 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
if (architecture == 'x64' && os != 'OSX10.12') {
//Flow jobs should be Windows, Ubuntu, OSX0.12, or CentOS
if (isFlowJob || os == 'Windows_NT') {
- Utilities.addGithubPushTrigger(job)
+ addGithubPushTriggerHelper(job)
}
// OSX10.12 r2r jobs should only run every 12 hours, not daily.
} else if (architecture == 'x64' && os == 'OSX10.12'){
if (isFlowJob) {
- Utilities.addPeriodicTrigger(job, 'H H/12 * * *')
+ addPeriodicTriggerHelper(job, 'H H/12 * * *')
}
}
// For x86, only add per-commit jobs for Windows
else if (architecture == 'x86') {
if (os == 'Windows_NT') {
- Utilities.addGithubPushTrigger(job)
+ addGithubPushTriggerHelper(job)
}
}
// arm64 r2r jobs should only run daily.
else if (architecture == 'arm64') {
if (os == 'Windows_NT') {
- Utilities.addPeriodicTrigger(job, '@daily')
+ addPeriodicTriggerHelper(job, '@daily')
}
}
}
@@ -766,13 +897,13 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
//Flow jobs should be Windows, Ubuntu, OSX10.12, or CentOS
if (isFlowJob || os == 'Windows_NT') {
// Add a weekly periodic trigger
- Utilities.addPeriodicTrigger(job, 'H H * * 3,6') // some time every Wednesday and Saturday
+ addPeriodicTriggerHelper(job, 'H H * * 3,6') // some time every Wednesday and Saturday
}
}
// For x86, only add per-commit jobs for Windows
else if (architecture == 'x86') {
if (os == 'Windows_NT') {
- Utilities.addPeriodicTrigger(job, 'H H * * 3,6') // some time every Wednesday and Saturday
+ addPeriodicTriggerHelper(job, 'H H * * 3,6') // some time every Wednesday and Saturday
}
}
}
@@ -781,7 +912,7 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
assert (os == 'Ubuntu' || os == 'Windows_NT' || os == 'OSX10.12')
assert configuration == 'Release'
assert architecture == 'x64'
- Utilities.addPeriodicTrigger(job, '@daily')
+ addPeriodicTriggerHelper(job, '@daily')
// TODO: Add once external email sending is available again
// addEmailPublisher(job, 'dotnetgctests@microsoft.com')
break
@@ -789,7 +920,7 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
assert (os == 'Ubuntu' || os == 'Windows_NT' || os == 'OSX10.12')
assert configuration == 'Release'
assert architecture == 'x64'
- Utilities.addPeriodicTrigger(job, 'H H * * 3,6') // some time every Wednesday and Saturday
+ addPeriodicTriggerHelper(job, 'H H * * 3,6') // some time every Wednesday and Saturday
// TODO: Add once external email sending is available again
// addEmailPublisher(job, 'dotnetgctests@microsoft.com')
break
@@ -798,7 +929,7 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
assert (configuration == 'Release' || configuration == 'Checked')
// TODO: Add once external email sending is available again
// addEmailPublisher(job, 'dotnetgctests@microsoft.com')
- Utilities.addPeriodicTrigger(job, '@daily')
+ addPeriodicTriggerHelper(job, '@daily')
break
case 'gc_reliability_framework':
assert (os == 'Ubuntu' || os == 'Windows_NT' || os == 'OSX10.12')
@@ -812,7 +943,7 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
// We don't expect to see a job generated except in these scenarios
assert (os == 'Windows_NT') || (os in Constants.crossList)
if (isFlowJob || os == 'Windows_NT') {
- Utilities.addPeriodicTrigger(job, '@daily')
+ addPeriodicTriggerHelper(job, '@daily')
}
}
break
@@ -820,12 +951,12 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
assert (os == 'Ubuntu' || os == 'Windows_NT' || os == 'OSX10.12')
assert configuration == 'Checked'
assert (architecture == 'x64' || architecture == 'x86')
- Utilities.addGithubPushTrigger(job)
+ addGithubPushTriggerHelper(job)
break
case 'formatting':
assert (os == 'Windows_NT' || os == "Ubuntu")
assert architecture == 'x64'
- Utilities.addGithubPushTrigger(job)
+ addGithubPushTriggerHelper(job)
break
case 'jitstressregs1':
case 'jitstressregs2':
@@ -868,11 +999,11 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
if ((architecture == 'arm64') || (architecture == 'arm') || (architecture == 'armlb')) {
if (os == 'Windows_NT') {
// We don't have enough ARM64 machines to run these more frequently than weekly.
- Utilities.addPeriodicTrigger(job, '@weekly')
+ addPeriodicTriggerHelper(job, '@weekly')
}
}
else {
- Utilities.addPeriodicTrigger(job, '@daily')
+ addPeriodicTriggerHelper(job, '@daily')
}
}
break
@@ -883,13 +1014,13 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
if ((architecture == 'arm64') || (architecture == 'arm') || (architecture == 'armlb')) {
if (os == 'Windows_NT') {
// We don't have enough ARM64 machines to run these more frequently than weekly.
- Utilities.addPeriodicTrigger(job, '@weekly')
+ addPeriodicTriggerHelper(job, '@weekly')
}
// TODO: Add once external email sending is available again
// addEmailPublisher(job, 'dotnetonarm64@microsoft.com')
}
else {
- Utilities.addPeriodicTrigger(job, '@weekly')
+ addPeriodicTriggerHelper(job, '@weekly')
}
}
break
@@ -906,13 +1037,13 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
if ((architecture == 'arm64') || (architecture == 'arm') || (architecture == 'armlb')) {
if (os == 'Windows_NT') {
// We don't have enough ARM64 machines to run these more frequently than weekly.
- Utilities.addPeriodicTrigger(job, '@weekly')
+ addPeriodicTriggerHelper(job, '@weekly')
}
// TODO: Add once external email sending is available again
// addEmailPublisher(job, 'dotnetonarm64@microsoft.com')
}
else {
- Utilities.addPeriodicTrigger(job, '@weekly')
+ addPeriodicTriggerHelper(job, '@weekly')
}
}
break
@@ -922,7 +1053,7 @@ def static addNonPRTriggers(def job, def branch, def isPR, def architecture, def
assert (os == 'Windows_NT' || os == 'Ubuntu')
if (architecture == 'x64' || architecture == 'x86') {
if (configuration == 'Checked') {
- Utilities.addPeriodicTrigger(job, '@daily')
+ addPeriodicTriggerHelper(job, '@daily')
}
}
break
@@ -2077,6 +2208,7 @@ Constants.allScenarios.each { scenario ->
// Create the new job
def newJob = job(Utilities.getFullJobName(project, jobName, isPR, folderName)) {}
+ addToViews(newJob, isPR, architecture, os)
def machineAffinityOptions = null
@@ -2683,6 +2815,8 @@ Constants.allScenarios.each { scenario ->
}
}
+ addToViews(newJob, isPR, architecture, os)
+
if (scenario == 'jitdiff') {
Utilities.addArchival(newJob, "bin/tests/${osGroup}.${architecture}.${configuration}/dasm/**")
}
@@ -2771,6 +2905,8 @@ build(params + [CORECLR_BUILD: coreclrBuildJob.build.number,
}
}
+ addToViews(newFlowJob, isPR, architecture, os)
+
// For the flow jobs set the machine affinity as x64 if an armarch.
def flowArch = architecture