From b3eb5df154e9500d4e91318b607e9f2732f8039e Mon Sep 17 00:00:00 2001 From: Andrei Piankouski Date: Wed, 20 Nov 2024 15:28:13 +0300 Subject: [PATCH] EPMRPP-97122 || Update java --- .github/workflows/build.yml | 4 +-- .github/workflows/manually-release.yml | 4 +-- .github/workflows/release.yml | 4 +-- build.gradle | 46 ++++++++++++------------ gradle.properties | 3 +- gradle/wrapper/gradle-wrapper.properties | 2 +- jitpack.yml | 2 +- jooq.gradle | 10 +++--- project-properties.gradle | 6 ++-- 9 files changed, 39 insertions(+), 42 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a508772bc..e89896ff7 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -18,11 +18,11 @@ jobs: - name: Checkout repository uses: actions/checkout@v2 - - name: Set up JDK 11 + - name: Set up JDK 21 uses: actions/setup-java@v2 with: distribution: 'adopt' - java-version: '11' + java-version: '21' - name: Grant execute permission for gradlew run: chmod +x gradlew diff --git a/.github/workflows/manually-release.yml b/.github/workflows/manually-release.yml index 3049e696c..1d645d983 100644 --- a/.github/workflows/manually-release.yml +++ b/.github/workflows/manually-release.yml @@ -31,11 +31,11 @@ jobs: - name: Checkout repository uses: actions/checkout@v2 - - name: Set up JDK 11 + - name: Set up JDK 21 uses: actions/setup-java@v2 with: distribution: 'adopt' - java-version: '11' + java-version: '21' - name: Grant execute permission for gradlew run: chmod +x gradlew diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ad723c672..3011bb00d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -23,11 +23,11 @@ jobs: - name: Checkout repository uses: actions/checkout@v2 - - name: Set up JDK 11 + - name: Set up JDK 21 uses: actions/setup-java@v2 with: distribution: 'adopt' - java-version: '11' + java-version: '21' - name: Grant execute permission for gradlew run: chmod +x gradlew diff --git a/build.gradle b/build.gradle index 49c949b87..eefa2a2f9 100644 --- a/build.gradle +++ b/build.gradle @@ -4,16 +4,16 @@ plugins { id 'io.spring.dependency-management' version '1.0.9.RELEASE' id 'java' id 'java-library' - id 'nu.studer.jooq' version '3.0.3' - id 'org.owasp.dependencycheck' version '5.3.1' + id 'org.owasp.dependencycheck' version '11.1.0' + id "org.jooq.jooq-codegen-gradle" version "${jooqVersion}" } apply from: 'project-properties.gradle' apply from: "$scriptsUrl/release-commons.gradle" apply from: "$scriptsUrl/signing.gradle" apply from: "$scriptsUrl/copy-database-scripts.gradle" -apply from: "$scriptsUrl/build-quality.gradle" -apply from: "$scriptsUrl/jacoco.gradle" +//apply from: "$scriptsUrl/build-quality.gradle" +//apply from: "$scriptsUrl/jacoco.gradle" apply from: 'jooq.gradle' repositories { @@ -33,9 +33,9 @@ dependencyManagement { dependencies { if (releaseMode) { - compile 'com.epam.reportportal:commons' + implementation 'com.epam.reportportal:commons' } else { - implementation 'com.github.reportportal:commons:d4be022' + implementation 'com.github.reportportal:commons:e55b9e6' } implementation 'org.springframework.security:spring-security-core' @@ -43,7 +43,7 @@ dependencies { implementation 'org.apache.tika:tika-core' //https://nvd.nist.gov/vuln/detail/CVE-2020-10683 (dom4j 2.1.3 version dependency) AND https://nvd.nist.gov/vuln/detail/CVE-2019-14900 - compile('org.springframework.boot:spring-boot-starter-data-jpa') { + implementation('org.springframework.boot:spring-boot-starter-data-jpa') { exclude group: 'org.hibernate', module: 'hibernate-core' } implementation 'org.springframework:spring-jdbc:5.3.33' @@ -51,31 +51,29 @@ dependencies { // //https://nvd.nist.gov/vuln/detail/CVE-2020-13692 - compile 'org.postgresql:postgresql:42.7.3' - compile 'org.jooq:jooq' - jooqRuntime 'org.postgresql:postgresql:42.7.3' + implementation 'org.postgresql:postgresql:42.7.3' + implementation 'org.jooq:jooq' - compile 'io.minio:minio:6.0.13' + implementation 'io.minio:minio:6.0.13' implementation group: 'org.json', name: 'json', version: '20231013' - compile 'com.fasterxml.jackson.datatype:jackson-datatype-jsr310' - compile 'org.hibernate.validator:hibernate-validator' + implementation 'com.fasterxml.jackson.datatype:jackson-datatype-jsr310' + implementation 'org.hibernate.validator:hibernate-validator' - compile 'org.apache.commons:commons-collections4:4.4' - compile 'commons-fileupload:commons-fileupload:1.4' - compile('commons-validator:commons-validator:1.6') { + implementation 'org.apache.commons:commons-collections4:4.4' + implementation 'commons-fileupload:commons-fileupload:1.4' + implementation('commons-validator:commons-validator:1.6') { exclude group: 'commons-beanutils', module: 'commons-beanutils' } - compile 'org.jasypt:jasypt:1.9.3' + implementation 'org.jasypt:jasypt:1.9.3' - compile 'io.zonky.test:embedded-postgres:2.0.6' - //Fix CVE-2024-25710, CVE-2024-26308 - compile 'org.apache.commons:commons-compress:1.26.0' - compile 'org.flywaydb:flyway-core:6.3.1' + implementation 'io.zonky.test:embedded-postgres:2.0.6' + implementation 'org.apache.commons:commons-compress:1.26.0' + implementation 'org.flywaydb:flyway-core:6.3.1' - compile 'org.apache.jclouds.api:s3:2.5.0' - compile 'org.apache.jclouds.provider:aws-s3:2.5.0' + implementation 'org.apache.jclouds.api:s3:2.5.0' + implementation 'org.apache.jclouds.provider:aws-s3:2.5.0' implementation 'org.apache.jclouds.api:filesystem:2.5.0' // add lombok support @@ -112,4 +110,4 @@ tasks.withType(JavaCompile) { checkCommitNeeded.dependsOn removeScripts test.dependsOn copyTestDatabaseScripts -build.dependsOn jacocoTestReport +//build.dependsOn jacocoTestReport diff --git a/gradle.properties b/gradle.properties index cae3fcc45..a77423a6c 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,2 +1,3 @@ version=5.11.7 -lombokVersion=1.18.30 \ No newline at end of file +lombokVersion=1.18.30 +jooqVersion=3.19.13 \ No newline at end of file diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index c8ce83d67..3da942798 100755 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ #Fri Mar 13 21:13:13 MSK 2020 -distributionUrl=https\://services.gradle.org/distributions/gradle-6.0-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-all.zip distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStorePath=wrapper/dists diff --git a/jitpack.yml b/jitpack.yml index 46c852919..a20279256 100644 --- a/jitpack.yml +++ b/jitpack.yml @@ -1,2 +1,2 @@ jdk: - - openjdk11 \ No newline at end of file + - openjdk21 \ No newline at end of file diff --git a/jooq.gradle b/jooq.gradle index 25c643f1d..a966fdd4b 100644 --- a/jooq.gradle +++ b/jooq.gradle @@ -1,7 +1,5 @@ jooq { - version = '3.12.4' - edition = 'OSS' - sample(sourceSets.main) { + configuration { jdbc { driver = 'org.postgresql.Driver' url = 'jdbc:postgresql://localhost:5432/reportportal' @@ -47,6 +45,6 @@ jooq { } } -generateSampleJooqSchemaSource { - enabled = false -} +//generateSampleJooqSchemaSource { +// enabled = false +//} diff --git a/project-properties.gradle b/project-properties.gradle index 893ceed4c..e81ec10cf 100755 --- a/project-properties.gradle +++ b/project-properties.gradle @@ -1,5 +1,5 @@ -sourceCompatibility = JavaVersion.VERSION_11 -targetCompatibility = JavaVersion.VERSION_11 +sourceCompatibility = JavaVersion.VERSION_21 +targetCompatibility = JavaVersion.VERSION_21 def commonScriptsUrl = 'https://raw.githubusercontent.com/reportportal/gradle-scripts/' def migrationsScriptsUrl = 'https://raw.githubusercontent.com/reportportal/migrations/' @@ -113,5 +113,5 @@ project.ext { } wrapper { - gradleVersion = '6.0' + gradleVersion = '8.10' }