feat(api, build): Upgrade to Java 25, Gradle 9, and Spring Boot 4, Jackson 3 (#2597)
* refactor: simplify RestTemplate and ObjectMapper configurations, add no-args constructors to progress classes Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * chore: update Gradle and Java versions in Docker configuration and build files Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * test: enhance header assertions in tests and add spring-boot-test-autoconfigure dependency Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * refactor(tests): migrate to SpringBootTest and update entity management in test cases Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * test: update test property configurations for H2 database in Healthcheck and BookOpds repository tests Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * test: clean up HealthcheckControllerTest by removing unnecessary whitespace and comments Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * test: remove unnecessary whitespace in HealthcheckControllerTest Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * chore: downgrade Flyway version from 12.0.0 to 11.14.1 in build.gradle Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * chore: downgrade Flyway version from 12.0.0 to 11.14.1 in build.gradle Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: add @DependsOn annotation for Flyway in MultipartConfig Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: add @DependsOn annotation for Flyway in LibraryService Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: add test configuration for Flyway in HealthcheckControllerTest chore: remove unused path variable in deleteLibrary method of LibraryService Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: configure Flyway migration and update test configuration Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: enable remote debugging in bootRun configuration Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: update Flyway version and enhance ObjectMapper configuration Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: remove @DependsOn annotation for Flyway in MultipartConfig and LibraryService Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: add NoArgsConstructor and AllArgsConstructor annotations to DTO classes Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: add NoArgsConstructor and AllArgsConstructor annotations to FileProcessResult, MetadataUpdateContext, and MetadataUpdateWrapper classes Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: add DependsOnDatabaseInitialization annotation to MultipartConfig, AppSettingService, LibraryService, and JwtSecretService classes Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: add DependsOnDatabaseInitialization annotation to MultipartConfig and CronService classes Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: implement lazy initialization and thread safety for JWT secret retrieval Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: add Flyway dependency and update LibraryService initialization to use ApplicationReadyEvent Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * refactor: remove outdated comments from JwtSecretService class Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * refactor: migrate from com.fasterxml.jackson to tools.jackson for JSON processing Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * refactor: remove unused ObjectMapper bean and related imports from JacksonConfig Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: configure async support with VirtualThreadTaskExecutor in WebMvcConfig Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: enhance application performance with virtual threads and HTTP/2 support Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: add JsonSetter annotation to skip null values for triggeredByCron field Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: add triggeredByCron field to TaskCreateRequest and initialize in task management Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * feat: enable Spring Data web support with DTO serialization in WebMvcConfig Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * refactor(UserDefaultsService): simplify class structure and remove unused methods Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * refactor(BookOpdsRepositoryDataJpaTest): simplify test setup and use TestEntityManager Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * refactor(BookOpdsRepositoryDataJpaTest): update test configuration and simplify entity persistence Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * refactor: update Jackson dependencies and migrate to Jackson 3 Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * refactor(build.gradle): update jackson-annotations dependency to use Jackson 3 BOM Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * refactor(BookOpdsRepositoryDataJpaTest): remove unused ObjectMapper bean definition Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> * refactor(LibraryService): simplify library deletion logic Signed-off-by: Balázs Szücs <bszucs1209@gmail.com> --------- Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
plugins {
|
||||
id 'java'
|
||||
id 'org.springframework.boot' version '3.5.8'
|
||||
id 'org.springframework.boot' version '4.0.2'
|
||||
id 'io.spring.dependency-management' version '1.1.7'
|
||||
id 'org.hibernate.orm' version '6.6.36.Final'
|
||||
id 'org.hibernate.orm' version '7.2.0.Final'
|
||||
id 'com.github.ben-manes.versions' version '0.53.0'
|
||||
}
|
||||
|
||||
@@ -11,7 +11,7 @@ version = '0.0.1-SNAPSHOT'
|
||||
|
||||
java {
|
||||
toolchain {
|
||||
languageVersion = JavaLanguageVersion.of(21)
|
||||
languageVersion = JavaLanguageVersion.of(25)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -41,7 +41,8 @@ dependencies {
|
||||
implementation 'io.projectreactor:reactor-core'
|
||||
|
||||
// --- Database & Migration ---
|
||||
implementation 'org.mariadb.jdbc:mariadb-java-client:3.5.6'
|
||||
implementation 'org.mariadb.jdbc:mariadb-java-client:3.5.7'
|
||||
implementation 'org.springframework.boot:spring-boot-starter-flyway'
|
||||
implementation 'org.flywaydb:flyway-mysql:11.19.0'
|
||||
|
||||
// --- Security & Authentication ---
|
||||
@@ -77,7 +78,6 @@ dependencies {
|
||||
implementation 'com.github.junrar:junrar:7.5.7'
|
||||
|
||||
// --- JSON & Web Scraping ---
|
||||
implementation 'com.fasterxml.jackson.datatype:jackson-datatype-jsr310:2.20.1'
|
||||
implementation 'org.jsoup:jsoup:1.21.2'
|
||||
|
||||
// --- Mapping (DTOs & Entities) ---
|
||||
@@ -93,11 +93,22 @@ dependencies {
|
||||
// --- Template Engine ---
|
||||
implementation 'org.freemarker:freemarker:2.3.34'
|
||||
|
||||
// --- Jackson 3 ---
|
||||
implementation platform('tools.jackson:jackson-bom:3.0.4')
|
||||
implementation 'tools.jackson.core:jackson-core'
|
||||
implementation 'tools.jackson.core:jackson-databind'
|
||||
implementation 'tools.jackson.module:jackson-module-blackbird'
|
||||
|
||||
// --- Jackson 2 (Compatibility) ---
|
||||
// jackson-annotations version is managed by Jackson 3 BOM (requires 2.20+)
|
||||
implementation 'com.fasterxml.jackson.core:jackson-annotations'
|
||||
|
||||
// --- Caching ---
|
||||
implementation 'com.github.ben-manes.caffeine:caffeine:3.2.0'
|
||||
|
||||
// --- Test Dependencies ---
|
||||
testImplementation 'org.springframework.boot:spring-boot-starter-test'
|
||||
testImplementation 'org.springframework.boot:spring-boot-test-autoconfigure'
|
||||
testImplementation 'org.assertj:assertj-core:3.27.6'
|
||||
testImplementation "org.mockito:mockito-inline:5.2.0"
|
||||
testRuntimeOnly 'com.h2database:h2'
|
||||
@@ -119,4 +130,8 @@ bootRun {
|
||||
if (debug.equals("true")) {
|
||||
jvmArgs("-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005")
|
||||
}
|
||||
}
|
||||
|
||||
bootJar {
|
||||
mainClass = 'org.booklore.BookloreApplication'
|
||||
}
|
||||
Reference in New Issue
Block a user