Skip to content

Commit fa17742

Browse files
author
Jonathan Henrique Medeiros
committed
feature: upgrade for Java 21 and Spring Boot 3.1.4
1 parent 3b67cd4 commit fa17742

File tree

9 files changed

+94
-82
lines changed

9 files changed

+94
-82
lines changed

.github/workflows/maven.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@ jobs:
1515
- name: Checkout project
1616
uses: actions/checkout@v3
1717

18-
- name: Configure AdoptOpenJDK 17
18+
- name: Configure Azul Zulu OpenJDK 21
1919
uses: actions/setup-java@v2
2020
with:
21-
java-version: "17"
22-
distribution: "adopt"
21+
java-version: "21"
22+
distribution: "zulu"
2323

2424
- name: Maven build
2525
run: mvn -B package --file pom.xml

.github/workflows/vulnerability_scan.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@ jobs:
2424
- name: Checkout repository
2525
uses: actions/checkout@v3
2626

27-
- name: Configure AdoptOpenJDK 17
27+
- name: Configure Configure Azul Zulu OpenJDK 21
2828
uses: actions/setup-java@v2
2929
with:
30-
java-version: "17"
31-
distribution: "adopt"
30+
java-version: "21"
31+
distribution: "zulu"
3232

3333
- name: Initialize CodeQL
3434
uses: github/codeql-action/init@v2

Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
FROM maven:3.8.5-openjdk-17 AS build
1+
FROM maven:3.9.4-amazoncorretto-21 AS build
22

33
COPY pom.xml .
44
RUN mvn dependency:go-offline
55

66
COPY src src
77
RUN mvn package
88

9-
FROM openjdk:17.0.2 AS release
9+
FROM azul/zulu-openjdk:21 AS release
1010

1111
COPY --from=build /target/*.jar /app.jar
1212

13-
ADD https://github.com/open-telemetry/opentelemetry-java-instrumentation/releases/latest/download/opentelemetry-javaagent.jar /
13+
ADD https://github.com/open-telemetry/opentelemetry-java-instrumentation/releases/download/v1.30.0/opentelemetry-javaagent.jar /
1414

1515
COPY docker-entrypoint.sh /
1616

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ Esta arquitetura consiste em diminuir a concorrência entre transações da API
1616
</br>
1717
</br>
1818

19-
[![node](https://img.shields.io/badge/AdoptOpenJDK-17-red.svg)](https://adoptopenjdk.net/)
20-
[![node](https://img.shields.io/badge/Spring_Boot-3.1.3-green.svg)](https://spring.io/)
19+
[![node](https://img.shields.io/badge/AdoptOpenJDK-21-red.svg)](https://adoptopenjdk.net/)
20+
[![node](https://img.shields.io/badge/Spring_Boot-3.1.4-green.svg)](https://spring.io/)
2121
[![node](https://img.shields.io/badge/MySQL-8.0.28-blue.svg)](https://www.mysql.com/)
2222

2323

agents/opentelemetry-javaagent.jar

147 KB
Binary file not shown.

docs/replication-databases

Lines changed: 75 additions & 68 deletions
Large diffs are not rendered by default.

docs/replication-databases.png

1.81 KB
Loading

pom.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<groupId>org.springframework.boot</groupId>
77
<artifactId>spring-boot-starter-parent</artifactId>
8-
<version>3.1.3</version>
8+
<version>3.1.4</version>
99
<relativePath/>
1010
</parent>
1111

@@ -15,15 +15,15 @@
1515
<name>multidatasources</name>
1616

1717
<properties>
18-
<java.version>17</java.version>
18+
<java.version>21</java.version>
1919
<maven.compiler.source>${java.version}</maven.compiler.source>
2020
<maven.compiler.target>${java.version}</maven.compiler.target>
2121
<mapstruct.version>1.5.5.Final</mapstruct.version>
2222
<logstash-logback-encoder.version>7.4</logstash-logback-encoder.version>
2323
<springdoc-openapi-starter-webmvc-ui.version>2.2.0</springdoc-openapi-starter-webmvc-ui.version>
2424
<snakeyaml.version>2.2</snakeyaml.version>
2525
<h2.version>2.2.220</h2.version>
26-
<opentelemetry.version>1.29.0</opentelemetry.version>
26+
<opentelemetry.version>1.30.0</opentelemetry.version>
2727
</properties>
2828

2929
<dependencyManagement>

src/main/resources/application.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,11 @@ spring:
5858
"[hibernate.connection.provider_disables_autocommit]": true
5959
"[hibernate.connection.handling_mode]": DELAYED_ACQUISITION_AND_RELEASE_AFTER_TRANSACTION
6060

61+
# SPRING VIRTUAL THREADS FOR JAVA 21
62+
threads:
63+
virtual:
64+
enabled: true
65+
6166
# OPEN API CONFIGURATION
6267
springdoc:
6368
api-docs:

0 commit comments

Comments
 (0)