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).
+// **************************************************************
+
+// MergeJobView: include all jobs that execute when a PR change is merged.
+def MergeJobView = listView('Merge') {
+ columns {
+ status()
+ weather()
+ name()
+ lastSuccess()
+ lastFailure()
+ lastDuration()
+ buildButton()
+ }
+}
+
+// PeriodicJobView: include all jobs that execute on a schedule
+def PeriodicJobView = listView('Periodic') {
+ columns {
+ status()
+ weather()
+ name()
+ lastSuccess()
+ lastFailure()
+ lastDuration()
+ buildButton()
+ }
+}
+
+// Create a view for non-PR jobs for each architecture.
+def ArchitectureViews = [:]
+Constants.architectureList.each { architecture ->
+ ArchitectureViews[architecture] = listView(architecture) {
+ columns {
+ status()
+ weather()
+ name()
+ lastSuccess()
+ lastFailure()
+ lastDuration()
+ buildButton()
+ }
+ }
+}
+
+// Create a view for non-PR jobs for each OS.
+def OSViews = [:]
+Constants.osList.each { os ->
+ // Don't create one for the special 'Windows_NT_BuildOnly'
+ if (os == 'Windows_NT_BuildOnly') {
+ return
+ }
+ OSViews[os] = listView(os) {
+ columns {
+ status()
+ weather()
+ name()
+ lastSuccess()
+ lastFailure()
+ lastDuration()
+ buildButton()
+ }
+ }
+}
+
+def static addToMergeView(def job) {
+ MergeJobView.with {
+ jobs {
+ name(job.name)
+ }
+ }
+}
+
+def static addToPeriodicView(def job) {
+ 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.
+ ArchitectureViews[architecture].with {
+ jobs {
+ name(job.name)
+ }
+ }
+
+ // Add to OS view.
+ 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
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}");
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')
}
}
}
//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
}
}
}
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
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
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')
// 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
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':
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
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
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
assert (os == 'Windows_NT' || os == 'Ubuntu')
if (architecture == 'x64' || architecture == 'x86') {
if (configuration == 'Checked') {
- Utilities.addPeriodicTrigger(job, '@daily')
+ addPeriodicTriggerHelper(job, '@daily')
}
}
break
// Create the new job
def newJob = job(Utilities.getFullJobName(project, jobName, isPR, folderName)) {}
+ addToViews(newJob, isPR, architecture, os)
def machineAffinityOptions = null
}
}
+ addToViews(newJob, isPR, architecture, os)
+
if (scenario == 'jitdiff') {
Utilities.addArchival(newJob, "bin/tests/${osGroup}.${architecture}.${configuration}/dasm/**")
}
}
}
+ addToViews(newFlowJob, isPR, architecture, os)
+
// For the flow jobs set the machine affinity as x64 if an armarch.
def flowArch = architecture