Update CI workflow to work on new infra (#123)

* Update CI workflow to work on new infra

- Backward compatability tests are disabled during CI by default #113
- Added property to allow for disabling bwc tests
- Added agent label to use specific hardware https://www.jenkins.io/doc/book/pipeline/syntax/#agent

Signed-off-by: Peter Nied <petern@amazon.com>
This commit is contained in:
Peter Nied 2021-02-23 19:00:56 -06:00
parent 4ff54fdac8
commit a54348b678
2 changed files with 11 additions and 4 deletions

6
Jenkinsfile vendored
View File

@ -1,11 +1,13 @@
pipeline {
agent any
agent { label 'search-cloud-ec2-c518xlarge' }
stages {
stage('Build') {
steps {
echo 'Building..'
sh './gradlew check --no-daemon'
// Disable backward compability tasks
sh './gradlew check --no-daemon --no-scan -Pbwc_tests_enabled=false'
}
}
stage('Test') {

View File

@ -170,8 +170,13 @@ tasks.register("verifyVersions") {
* after the backport of the backcompat code is complete.
*/
boolean bwc_tests_enabled = true
final String bwc_tests_disabled_issue = "" /* place a PR link here when committing bwc changes */
boolean bwc_tests_enabled = false
String bwc_tests_disabled_issue = "" /* place a PR link here when committing bwc changes */
if (project.findProperty("bwc_tests_enabled") != null) {
bwc_tests_enabled = Boolean.parseBoolean(project.findProperty("bwc_tests_enabled"))
bwc_tests_disabled_issue = "Backward compatibility tests disabled via commandline"
}
if (bwc_tests_enabled == false) {
if (bwc_tests_disabled_issue.isEmpty()) {
throw new GradleException("bwc_tests_disabled_issue must be set when bwc_tests_enabled == false")