Skip to content

Commit

Permalink
Migrated to JDK21
Browse files Browse the repository at this point in the history
  • Loading branch information
oharsta committed Oct 25, 2024
1 parent 961296d commit 4830db3
Show file tree
Hide file tree
Showing 8 changed files with 19 additions and 19 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ jobs:
- name: Yarn Audit welcome
run: yarn audit --level high --groups dependencies
working-directory: welcome
- name: Set up JDK 17
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '17'
java-version: '21'
distribution: 'adopt'
cache: 'maven'
- name: Set up MySQL
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,10 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up JDK 17
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '17'
java-version: '21'
distribution: 'adopt'

# Initializes the CodeQL tools for scanning.
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:

- uses: actions/setup-java@v4
with:
java-version: 17
java-version: 21
distribution: "temurin"

- name: Set up cache
Expand All @@ -53,21 +53,21 @@ jobs:
exit 1
if: github.event_name != 'workflow_dispatch' && steps.versioncheck.outputs.version != github.ref_name

- name: Set up JDK 17 for snapshots
- name: Set up JDK 21 for snapshots
uses: actions/setup-java@v4
with:
java-version: "17"
java-version: "21"
distribution: "temurin"
cache: "maven"
server-id: openconext-snapshots
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
if: ( endsWith(steps.versioncheck.outputs.version, '-SNAPSHOT'))

- name: Set up JDK 17 for releases
- name: Set up JDK 21 for releases
uses: actions/setup-java@v4
with:
java-version: "17"
java-version: "21"
distribution: "temurin"
cache: "maven"
server-id: openconext-releases
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/doc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ jobs:
- 'server/src/**'
# Generate the OpenApi spec json, only if the server component has changes
- name: Set up JDK 17
- name: Set up JDK 21
uses: actions/setup-java@v2
with:
java-version: '17'
java-version: '21'
distribution: 'adopt'
cache: 'maven'
if: ${{ steps.changes.outputs.server == 'true' || github.event_name == 'workflow_dispatch' }}
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@

### [System Requirements](#system-requirements)

- Java 17
- Java 21
- Maven 3

First install Java 17 with a package manager
First install Java 21 with a package manager
and then export the correct the `JAVA_HOME`. For example on macOS:

```bash
export JAVA_HOME=/Library/Java/JavaVirtualMachines/openjdk-17.jdk/Contents/Home/
export JAVA_HOME=/Library/Java/JavaVirtualMachines/openjdk-21.jdk/Contents/Home/
```

Then create the MySQL database:
Expand Down
6 changes: 3 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
</parent>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<java.version>17</java.version>
<java.version>21</java.version>
</properties>
<modules>
<module>server</module>
Expand All @@ -31,7 +31,7 @@
<artifactId>maven-compiler-plugin</artifactId>
<version>3.13.0</version>
<configuration>
<release>17</release>
<release>21</release>
</configuration>
</plugin>
<plugin>
Expand All @@ -50,7 +50,7 @@
<version>[3.8.7,)</version>
</requireMavenVersion>
<requireJavaVersion>
<version>17</version>
<version>21</version>
</requireJavaVersion>
</rules>
</configuration>
Expand Down
2 changes: 1 addition & 1 deletion provisioning-mock/docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM eclipse-temurin:17-jdk-alpine
FROM eclipse-temurin:21-jdk-alpine
COPY target/*.jar app.jar
ENTRYPOINT ["java","-jar","/app.jar"]

2 changes: 1 addition & 1 deletion server/docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM eclipse-temurin:17-jdk-alpine
FROM eclipse-temurin:21-jdk-alpine
COPY target/*.jar app.jar
ENTRYPOINT ["java","-jar","/app.jar"]

0 comments on commit 4830db3

Please sign in to comment.