chore(build): update JVM target to 25, enforce stable kotlinx-serialization-json, and add bundle size budget checks
- Updated Kotlin compiler and JVM toolchain to target JVM 25 in all subprojects. - Enforced stable `kotlinx-serialization-json:1.7.3` version to prevent resolution issues. - Introduced JS bundle size budget checks for frontend shells with gzip support and reporting. - Refined and reorganized Gradle module includes in `settings.gradle.kts`. - Removed legacy and redundant dependency configurations for improved clarity.
This commit is contained in:
@@ -7,7 +7,6 @@ plugins {
|
||||
alias(libs.plugins.kotlinSpring)
|
||||
alias(libs.plugins.kotlinJpa)
|
||||
alias(libs.plugins.spring.boot)
|
||||
alias(libs.plugins.spring.dependencyManagement)
|
||||
}
|
||||
|
||||
// Konfiguriert die Hauptklasse für das ausführbare JAR
|
||||
@@ -16,6 +15,7 @@ springBoot {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
// Wiederherstellung des Standardzustands: Das Gateway verwendet das reparierte lokale BOM.
|
||||
implementation(platform(projects.platform.platformBom))
|
||||
|
||||
// === Core Dependencies ===
|
||||
@@ -24,20 +24,16 @@ dependencies {
|
||||
implementation(projects.backend.infrastructure.monitoring.monitoringClient)
|
||||
|
||||
// === GATEWAY-SPEZIFISCHE ABHÄNGIGKEITEN ===
|
||||
// KORREKTUR: Explizite Deklaration von WebFlux, da es in Spring Boot 4.x
|
||||
// anscheinend nicht mehr vollständig transitiv vom Gateway-Starter eingebunden wird.
|
||||
implementation(libs.spring.boot.starter.webflux)
|
||||
// Die WebFlux-Abhängigkeit wird jetzt korrekt durch das BOM bereitgestellt.
|
||||
// implementation(libs.spring.boot.starter.webflux)
|
||||
|
||||
// Kern-Gateway inkl. Security, Actuator, CircuitBreaker, Discovery
|
||||
implementation(libs.bundles.gateway.core)
|
||||
// Ergänzende Observability (Logging, Jackson)
|
||||
implementation(libs.bundles.gateway.observability)
|
||||
// Redis-Unterstützung für verteiltes Rate Limiting (RequestRateLimiter)
|
||||
// Umgestellt auf das spezifische Gateway-Redis-Bundle (einfach, leicht zu konfigurieren)
|
||||
implementation(libs.bundles.gateway.redis)
|
||||
|
||||
// Hinweis: Der Gateway benötigt keinen Datenbanktreiber → entfernt
|
||||
|
||||
// === Test Dependencies ===
|
||||
testImplementation(projects.platform.platformTesting)
|
||||
testImplementation(libs.bundles.testing.jvm)
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@ package at.mocode.infrastructure.gateway.error
|
||||
|
||||
import com.fasterxml.jackson.databind.ObjectMapper
|
||||
import org.slf4j.LoggerFactory
|
||||
import org.springframework.boot.web.reactive.error.ErrorWebExceptionHandler
|
||||
import org.springframework.boot.webflux.error.ErrorWebExceptionHandler
|
||||
import org.springframework.http.HttpStatus
|
||||
import org.springframework.http.MediaType
|
||||
import org.springframework.stereotype.Component
|
||||
|
||||
+2
@@ -42,6 +42,8 @@ class GatewayHealthIndicator(
|
||||
private val HEALTH_CHECK_TIMEOUT = Duration.ofSeconds(5)
|
||||
}
|
||||
|
||||
// KORREKTUR für Spring Boot 4: Die `health()`-Methode und ihr Rückgabetyp `Mono<Health>`
|
||||
// erlauben keine Null-Werte mehr. Die Fragezeichen (?) wurden entfernt.
|
||||
override fun health(): Mono<Health> {
|
||||
val builder = Health.up()
|
||||
val details = mutableMapOf<String, Any>()
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@ import io.micrometer.core.instrument.Counter
|
||||
import io.micrometer.core.instrument.MeterRegistry
|
||||
import io.micrometer.core.instrument.Timer
|
||||
import io.micrometer.core.instrument.config.MeterFilter
|
||||
import org.springframework.boot.actuate.autoconfigure.metrics.MeterRegistryCustomizer
|
||||
import org.springframework.boot.micrometer.metrics.autoconfigure.MeterRegistryCustomizer
|
||||
import org.springframework.context.annotation.Bean
|
||||
import org.springframework.context.annotation.Configuration
|
||||
import org.springframework.web.server.ServerWebExchange
|
||||
|
||||
@@ -5,7 +5,8 @@ plugins {
|
||||
alias(libs.plugins.kotlinSpring)
|
||||
alias(libs.plugins.kotlinJpa)
|
||||
alias(libs.plugins.spring.boot)
|
||||
alias(libs.plugins.spring.dependencyManagement)
|
||||
// FINALE BEREINIGUNG: Das `dependencyManagement`-Plugin wird entfernt.
|
||||
// alias(libs.plugins.spring.dependencyManagement)
|
||||
}
|
||||
|
||||
// Configure the main class for the executable JAR
|
||||
@@ -14,10 +15,8 @@ springBoot {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
// ULTIMATIVER TEST: Wir umgehen unser lokales BOM und importieren das offizielle Spring Boot BOM direkt.
|
||||
// Wenn dies funktioniert, liegt der Fehler im Aufbau von `:platform:platform-bom`.
|
||||
implementation(platform(libs.spring.boot.dependencies))
|
||||
// implementation(platform(projects.platform.platformBom))
|
||||
// Die `platform`-Deklaration ist der einzig korrekte Weg.
|
||||
implementation(platform(projects.platform.platformBom))
|
||||
|
||||
// Platform und Core Dependencies
|
||||
implementation(projects.platform.platformDependencies)
|
||||
|
||||
Reference in New Issue
Block a user