- ./private/cirrus/cirrus-qa.sh postgres
<<: *DEFAULT_ARTIFACTS_TEMPLATE
-qa_java11_task:
- <<: *DEFAULT_TEMPLATE
- <<: *BUILD_DEPENDANT_TASK_TEMPLATE
- <<: *GRADLE_CACHE_TEMPLATE
- <<: *JAR_CACHE_TEMPLATE
- gke_container:
- dockerfile: private/docker/Dockerfile-build-java11
- builder_image_project: sonarqube-team
- builder_image_name: family/docker-builder
- cluster_name: cirrus-ci-cluster
- zone: us-central1-a
- namespace: default
- cpu: 2
- memory: 6Gb
- additional_containers:
- - <<: *POSTGRES_ADDITIONAL_CONTAINER_TEMPLATE
- env:
- matrix:
- - QA_CATEGORY: Cat1
- - QA_CATEGORY: CommunityEditionWithPlugins
- - QA_CATEGORY: ComputeEngine
- - QA_CATEGORY: Upgrade
- script:
- - ./private/cirrus/cirrus-qa.sh postgres
- <<: *DEFAULT_ARTIFACTS_TEMPLATE
-
task: #bitbucket
<<: *DEFAULT_TEMPLATE
<<: *BUILD_DEPENDANT_TASK_TEMPLATE
import groovy.json.JsonOutput
+import static org.gradle.api.JavaVersion.VERSION_17
+
plugins {
// Ordered alphabetically
id 'com.github.hierynomus.license' version '0.16.1'
id 'org.sonarqube' version '3.5.0.2730'
}
-if (!JavaVersion.current().java11Compatible) {
- throw new GradleException("JDK 11+ is required to perform this build. It's currently " + System.getProperty("java.home") + ".")
+if (!JavaVersion.current().isCompatibleWith(VERSION_17)) {
+ throw new GradleException("JDK 17+ is required to perform this build. It's currently " + System.getProperty("java.home") + ".")
}
/**
// do not deploy to Artifactory by default
artifactoryPublish.skip = true
- // Produce Java 11 bytecode while making sure the code does not use any APIs from Java 17
- compileJava.options.release = 11
-
compileJava.options.encoding = "UTF-8"
compileTestJava.options.encoding = "UTF-8"
artifactoryPublish.skip = false
+// Produce Java 11 bytecode while making sure the code does not use any APIs from Java 17
+tasks.withType(JavaCompile) {
+ options.release = 11
+}
+
publishing {
publications {
mavenJava(MavenPublication) {
testCompileOnly 'com.google.code.findbugs:jsr305'
}
+// Produce Java 11 bytecode while making sure the code does not use any APIs from Java 17
+tasks.withType(JavaCompile) {
+ options.release = 11
+}
+
// Used by sonar-db-core to run DB Unit Tests
artifactoryPublish.skip = false
publishing {
testImplementation 'org.hamcrest:hamcrest-core'
testImplementation 'org.mockito:mockito-core'
}
+
+// Produce Java 11 bytecode while making sure the code does not use any APIs from Java 17
+tasks.withType(JavaCompile) {
+ options.release = 11
+}
artifactoryPublish.skip = false
+// Produce Java 11 bytecode while making sure the code does not use any APIs from Java 17
+tasks.withType(JavaCompile) {
+ options.release = 11
+}
+
publishing {
publications {
mavenJava(MavenPublication) {
artifactoryPublish.skip = false
+// Produce Java 11 bytecode while making sure the code does not use any APIs from Java 17
+tasks.withType(JavaCompile) {
+ options.release = 11
+}
+
publishing {
publications {
mavenJava(MavenPublication) {
artifactoryPublish.skip = false
+// Produce Java 11 bytecode while making sure the code does not use any APIs from Java 17
+tasks.withType(JavaCompile) {
+ options.release = 11
+}
+
// Used by core plugins
publishing {
publications {
build.dependsOn fatJar
+// Produce Java 11 bytecode while making sure the code does not use any APIs from Java 17
+tasks.withType(JavaCompile) {
+ options.release = 11
+}
+
// Used by sonar-db-core to run DB Unit Tests
artifactoryPublish.skip = false
publishing {
compileOnlyApi 'com.google.code.findbugs:jsr305'
}
+// Produce Java 11 bytecode while making sure the code does not use any APIs from Java 17
+tasks.withType(JavaCompile) {
+ options.release = 11
+}
+
artifactoryPublish.skip = false
publishing {
publications {
artifactoryPublish.skip = false
+// Produce Java 11 bytecode while making sure the code does not use any APIs from Java 17
+tasks.withType(JavaCompile) {
+ options.release = 11
+}
+
publishing {
publications {
mavenJava(MavenPublication) {