Skip to content

Commit

Permalink
EPMRPP-97485 || Update to java 21 (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
APiankouski authored Dec 3, 2024
1 parent 580bca0 commit 6d1f45e
Show file tree
Hide file tree
Showing 64 changed files with 47 additions and 69 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/manually-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,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
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,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
Expand Down
42 changes: 14 additions & 28 deletions plugin-slack/build.gradle → build.gradle
Original file line number Diff line number Diff line change
@@ -1,20 +1,16 @@
import com.github.spotbugs.SpotBugsTask

plugins {
id "io.spring.dependency-management" version "1.0.9.RELEASE"
id "io.spring.dependency-management" version "1.1.4"
id 'java'
id 'jacoco'
id "com.github.spotbugs" version "3.0.0"
id "com.github.node-gradle.node" version "2.2.1"
}


node {
version = '20.11.0'
npmVersion = '10.2.4'
download = true
workDir = file("${project.buildDir}/plugin-slack/ui")
nodeModulesDir = file("${project.rootDir}/plugin-slack/ui")
workDir = file("${project.buildDir}/ui")
nodeModulesDir = file("${project.rootDir}/ui")
}

npm_run_build {
Expand Down Expand Up @@ -48,29 +44,19 @@ dependencies {
implementation 'com.epam.reportportal:plugin-api'
annotationProcessor 'com.epam.reportportal:plugin-api'
} else {
implementation 'com.github.reportportal:commons-dao:acf1ec7'
implementation 'com.github.reportportal:plugin-api:188792e'
annotationProcessor 'com.github.reportportal:plugin-api:188792e'
implementation 'com.github.reportportal:commons-dao:a98c172'
implementation 'com.github.reportportal:plugin-api:develop-SNAPSHOT'
annotationProcessor 'com.github.reportportal:plugin-api:develop-SNAPSHOT'
}

compile("com.slack.api:slack-api-client:1.27.1") {
implementation("com.slack.api:slack-api-client:1.27.1") {
exclude group: "org.slf4j"
}
compile 'com.squareup.okhttp3:okhttp:4.12.0'
implementation 'com.fasterxml.jackson.datatype:jackson-datatype-jsr310:2.18.2'
implementation 'com.squareup.okhttp3:okhttp:4.12.0'
implementation 'org.hibernate:hibernate-core:5.6.15.Final'
}

spotbugs {
sourceSets = [sourceSets.main]
reportLevel = "high"
}
tasks.withType(SpotBugsTask) {
reports {
xml.enabled false
html.enabled true
}
}

test {
useJUnitPlatform()
maxParallelForks = 1
Expand All @@ -79,7 +65,7 @@ test {
exceptionFormat = 'short'
}
reports {
junitXml.enabled = true
junitXml.required = true
}
}

Expand Down Expand Up @@ -109,7 +95,7 @@ jar {
}
manifest {
attributes(
"Class-Path": configurations.compile.collect { it.getName() }.join(' '),
"Class-Path": configurations.compileClasspath.collect { it.getName() }.join(' '),
"Plugin-Id": "${pluginId}",
"Plugin-Version": "${project.version}",
"Plugin-Provider": "Report Portal",
Expand All @@ -126,7 +112,7 @@ shadowJar {
from("ui/build") {
into("/resources")
}
configurations = [project.configurations.compile]
configurations = [project.configurations.compileClasspath]
zip64 true
dependencies {
}
Expand All @@ -138,9 +124,9 @@ task plugin(type: Jar) {
with jar
}
into('lib') {
from configurations.compile
from configurations.compileClasspath
}
extension('zip')
archiveExtension.set('zip')
}

task assemblePlugin(type: Copy) {
Expand Down
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
3 changes: 2 additions & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip
networkTimeout=10000
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
3 changes: 0 additions & 3 deletions plugin-slack/gradle.properties

This file was deleted.

24 changes: 0 additions & 24 deletions plugin-slack/project-properties.gradle

This file was deleted.

29 changes: 24 additions & 5 deletions project-properties.gradle
Original file line number Diff line number Diff line change
@@ -1,12 +1,31 @@
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
java {
sourceCompatibility = JavaVersion.VERSION_21
targetCompatibility = JavaVersion.VERSION_21
}

def commonScriptsUrl = 'https://raw.githubusercontent.com/reportportal/gradle-scripts/'

project.ext {
publishRepo = "https://maven.pkg.github.com/reportportal/plugin-slack"
releaseMode = project.hasProperty("releaseMode")
pluginsDir = "$buildDir/jars"

pluginsDir = "$buildDir/plugins"
scriptsUrl = commonScriptsUrl + (releaseMode ? getProperty('scripts.version') : 'develop')
excludeTests = [
'**/entity/**',
'**/model/**',
]
limits = [
'instruction': 30,
'branch' : 17,
'line' : 30,
'complexity' : 26,
'method' : 29,
'class' : 30
]
}

wrapper {
gradleVersion = '5.4.1'
gradleVersion = '8.10.2'
}


3 changes: 1 addition & 2 deletions settings.gradle
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
rootProject.name = 'plugin-slack-epam'
include 'plugin-slack'
rootProject.name = 'plugin-slack'

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 6d1f45e

Please sign in to comment.