Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add JDK 17 support #512

Merged
merged 7 commits into from
Mar 25, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions .github/workflows/sql-jdbc-test-and-build-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,24 @@ on: [push, pull_request]

jobs:
build:

strategy:
matrix:
java:
- 11
- 14
- 17
dai-chen marked this conversation as resolved.
Show resolved Hide resolved
runs-on: ubuntu-latest
defaults:
run:
working-directory: sql-jdbc

steps:
- uses: actions/checkout@v1
- name: Set up JDK 1.14

- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@v1
with:
java-version: 1.14
java-version: ${{ matrix.java }}

- name: Build with Gradle
run: ./gradlew build test shadowJar
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/sql-test-and-build-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ jobs:
java:
- 11
- 14
- 17
runs-on: ubuntu-latest

steps:
Expand Down
2 changes: 1 addition & 1 deletion DEVELOPER_GUIDE.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Prerequisites
JDK
---

OpenSearch builds using Java 11 at a minimum. This means you must have a JDK 11 installed with the environment variable `JAVA_HOME` referencing the path to Java home for your JDK 11 installation::
OpenSearch builds using Java 11 at a minimum and supports JDK 11, 14 and 17. This means you must have a JDK of supported version installed with the environment variable `JAVA_HOME` referencing the path to Java home for your JDK installation::

$ echo $JAVA_HOME
/Library/Java/JavaVirtualMachines/adoptopenjdk-11.jdk/Contents/Home
Expand Down
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ plugins {
id 'nebula.ospackage' version "8.3.0"
id 'java-library'
id 'checkstyle'
id "io.freefair.lombok" version "5.0.0-rc4"
id "io.freefair.lombok" version "6.4.0"
id 'jacoco'
}

Expand Down Expand Up @@ -80,7 +80,7 @@ compileTestJava {
}

jacoco {
toolVersion = "0.8.5"
toolVersion = "0.8.7"
}
jacocoTestReport {
reports {
Expand Down
7 changes: 2 additions & 5 deletions core/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ dependencies {
testImplementation('org.junit.jupiter:junit-jupiter:5.6.2')
testImplementation group: 'org.hamcrest', name: 'hamcrest-library', version: '2.1'
testImplementation group: 'org.springframework', name: 'spring-test', version: '5.2.19.RELEASE'
testImplementation group: 'org.mockito', name: 'mockito-core', version: '3.3.3'
testImplementation group: 'org.mockito', name: 'mockito-junit-jupiter', version: '3.3.3'
testImplementation group: 'org.mockito', name: 'mockito-core', version: '3.12.4'
testImplementation group: 'org.mockito', name: 'mockito-junit-jupiter', version: '3.12.4'
}

test {
Expand All @@ -62,9 +62,6 @@ test {
}
}

jacoco {
toolVersion = "0.8.5"
}
jacocoTestReport {
reports {
html.enabled true
Expand Down
2 changes: 1 addition & 1 deletion legacy/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ dependencies {
compileOnly group: 'javax.servlet', name: 'servlet-api', version:'2.5'

testImplementation group: 'org.hamcrest', name: 'hamcrest-core', version:'2.2'
testImplementation group: 'org.mockito', name: 'mockito-inline', version:'3.5.0'
testImplementation group: 'org.mockito', name: 'mockito-inline', version:'3.12.4'
testImplementation group: 'junit', name: 'junit', version: '4.13.2'
testImplementation group: "org.opensearch.client", name: 'transport', version: "${opensearch_version}"

Expand Down
7 changes: 2 additions & 5 deletions opensearch/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ dependencies {

testImplementation('org.junit.jupiter:junit-jupiter:5.6.2')
testImplementation group: 'org.hamcrest', name: 'hamcrest-library', version: '2.1'
testImplementation group: 'org.mockito', name: 'mockito-core', version: '3.5.0'
testImplementation group: 'org.mockito', name: 'mockito-junit-jupiter', version: '3.5.0'
testImplementation group: 'org.mockito', name: 'mockito-core', version: '3.12.4'
testImplementation group: 'org.mockito', name: 'mockito-junit-jupiter', version: '3.12.4'
testImplementation group: 'org.opensearch.client', name: 'opensearch-rest-high-level-client', version: "${opensearch_version}"
testImplementation group: 'org.opensearch.test', name: 'framework', version: "${opensearch_version}"
}
Expand All @@ -55,9 +55,6 @@ test {
}
}

jacoco {
toolVersion = "0.8.5"
}
jacocoTestReport {
reports {
html.enabled true
Expand Down
6 changes: 1 addition & 5 deletions ppl/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ dependencies {

testImplementation group: 'junit', name: 'junit', version: '4.13.2'
testImplementation group: 'org.hamcrest', name: 'hamcrest-library', version: '2.1'
testImplementation group: 'org.mockito', name: 'mockito-core', version: '3.3.3'
testImplementation group: 'org.mockito', name: 'mockito-core', version: '3.12.4'

}

Expand All @@ -68,10 +68,6 @@ test {
}
}

jacoco {
toolVersion = "0.8.5"
}

jacocoTestReport {
reports {
html.enabled true
Expand Down
7 changes: 2 additions & 5 deletions protocol/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ dependencies {

testImplementation('org.junit.jupiter:junit-jupiter:5.6.2')
testImplementation group: 'org.hamcrest', name: 'hamcrest-library', version: '2.1'
testImplementation group: 'org.mockito', name: 'mockito-core', version: '3.3.3'
testImplementation group: 'org.mockito', name: 'mockito-junit-jupiter', version: '3.3.3'
testImplementation group: 'org.mockito', name: 'mockito-core', version: '3.12.4'
testImplementation group: 'org.mockito', name: 'mockito-junit-jupiter', version: '3.12.4'
}

test {
Expand All @@ -51,9 +51,6 @@ test {
}
}

jacoco {
toolVersion = "0.8.5"
}
jacocoTestReport {
reports {
html.enabled true
Expand Down
8 changes: 2 additions & 6 deletions sql/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ dependencies {

testImplementation('org.junit.jupiter:junit-jupiter:5.6.2')
testImplementation group: 'org.hamcrest', name: 'hamcrest-library', version: '2.1'
testImplementation group: 'org.mockito', name: 'mockito-core', version: '3.3.3'
testImplementation group: 'org.mockito', name: 'mockito-junit-jupiter', version: '3.3.3'
testImplementation group: 'org.mockito', name: 'mockito-core', version: '3.12.4'
testImplementation group: 'org.mockito', name: 'mockito-junit-jupiter', version: '3.12.4'
}

test {
Expand All @@ -67,10 +67,6 @@ test {
}
}

jacoco {
toolVersion = "0.8.5"
}

jacocoTestReport {
reports {
html.enabled true
Expand Down