You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The `grails-micronaut-bom` layers Micronaut-specific dependency overrides on top of `grails-bom` and pins the `io.micronaut.platform:micronaut-platform` version it was built against. Applying it as `enforcedPlatform` makes all of its constraints strictly versioned so that no transitive dependency (including Micronaut's own platform) can override them — there is no need to set a `micronautPlatformVersion` Gradle property. See link:{versionsRef}Grails%20BOM%20Micronaut.html[Grails Micronaut BOM Dependencies] for the full list of managed versions.
44
+
The `grails-micronaut-bom` layers Micronaut-specific dependency overrides on top of `grails-bom` and pins the `io.micronaut.platform:micronaut-platform` version it was built against. Applying it as `enforcedPlatform` makes all of its constraints strictly versioned so that no transitive dependency, including Micronaut's own platform, can override them. There is no need to set a `micronautPlatformVersion` Gradle property. See link:{versionsRef}Grails%20BOM%20Micronaut.html[Grails Micronaut BOM Dependencies] for the full list of managed versions.
45
45
46
46
==== Hibernate-Specific Micronaut BOMs
47
47
@@ -80,12 +80,13 @@ The Micronaut auto-setup defaults to on. If a project deliberately deviates from
80
80
.build.gradle
81
81
----
82
82
grails {
83
-
micronautAutoSetup = false // not recommended — also skips the bootJar/bootWar CLASSIC loader configuration
83
+
micronautAutoSetup = false // not recommended - also skips Micronaut BOM validation
84
84
}
85
85
----
86
86
87
-
WARNING: Disabling auto-setup is rarely appropriate. Without `enforcedPlatform`, Gradle's default conflict resolution allows the Micronaut platform to silently override grails-bom-managed versions of libraries such as Groovy and `javaparser-core`, leading to binary incompatibilities at runtime. The CLASSIC loader configuration that auto-setup provides is also required for `java -jar` compatibility with the Micronaut-Spring integration.
87
+
WARNING: Disabling auto-setup is rarely appropriate. Without auto-setup, the Grails Gradle plugin will not validate that a Micronaut-compatible BOM is applied as `enforcedPlatform`. Without `enforcedPlatform`, Gradle's default conflict resolution allows the Micronaut platform to silently override the selected Grails Micronaut BOM versions of libraries such as Groovy and `javaparser-core`, leading to binary incompatibilities at runtime.
88
88
89
89
==== Generated Applications
90
90
91
-
Applications generated by https://forge.grails.org/[Grails Forge] with the Micronaut feature selected automatically use `enforcedPlatform("org.apache.grails:grails-micronaut-bom:$grailsVersion")` and require no further setup.
91
+
Applications generated by https://forge.grails.org/[Grails Forge] with the Micronaut feature selected automatically use `enforcedPlatform("org.apache.grails:grails-micronaut-bom:$grailsVersion")` and require no further setup.
92
+
In Grails 8, Micronaut-enabled applications require JDK 25 or later; applications that do not use Micronaut continue to use the standard Java 21 baseline.
Copy file name to clipboardExpand all lines: grails-doc/src/en/guide/introduction/whatsNew.adoc
+12-1Lines changed: 12 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,6 +27,18 @@ This release focuses on enhancing the developer experience, improving performanc
27
27
For detailed information on how to upgrade to Grails {grailsMajorVersion}, including major dependency changes, please see the xref:upgrading#upgrading80x[Upgrading from Grails 7 to Grails {grailsMajorVersion}] section.
28
28
Notable new features are included below.
29
29
30
+
==== Platform Baseline
31
+
32
+
Grails {grailsMajorVersion} raises the standard build and runtime baseline to Java 21 and uses Gradle {gradleVersion}.
33
+
The standard Grails BOM remains on Groovy {groovyVersion} and Spock {spockVersion}, while Micronaut-enabled Grails applications use Micronaut-specific BOM variants that align with Micronaut 5 and require JDK 25 or later.
34
+
35
+
==== Spring Boot 4.1 and Spring Framework 7
36
+
37
+
Grails {grailsMajorVersion} is built on Spring Boot {springBootVersion} and Spring Framework {springVersion}.
38
+
This brings the Spring Boot 4 modular artifact layout, Spring Framework 7 API removals, Jackson 3, Tomcat 11 and Jakarta Servlet 6.1, plus Spring Boot 4.1 dependency management for Spring Security 7.1, Spring Data 2026.0 and Micrometer 1.17.
39
+
40
+
The Grails 8 upgrade guide calls out the major application-impacting changes and links to the Spring Boot 4.0 migration guide, Spring Boot 4.1 release notes and Spring Framework 7.0 release notes.
41
+
30
42
==== GSP Tag Library Improvements
31
43
32
44
Grails {grailsMajorVersion} continues the move toward method-based TagLib handlers while preserving compatibility with existing closure-based tags.
@@ -90,4 +102,3 @@ A single property can likewise declare a `$text` index — or another special ty
90
102
When the options of an already-created index change between restarts, GORM now reconciles the difference instead of only
91
103
logging a conflict. A changed TTL is applied in place with MongoDB's `collMod` command — no drop, no rebuild — while any
92
104
other option change is applied by declaring `indexAttributes: [recreateOnConflict: true]`.
Copy file name to clipboardExpand all lines: grails-doc/src/en/guide/introduction/whatsNew/dependencyUpgrades.adoc
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,9 +19,11 @@ under the License.
19
19
20
20
Grails {version} ships with the following foundational dependency versions:
21
21
22
+
* Java 21 minimum baseline
22
23
* Groovy {groovyVersion}
23
24
* Spring Framework {springVersion}
24
25
* Spring Boot {springBootVersion}
25
26
* Gradle {gradleVersion}
26
27
* Spock {spockVersion}
27
28
29
+
See the link:{versionsRef}Grails%20BOM.html[Grails BOM dependency table] for the complete managed dependency set, including the Hibernate and Micronaut BOM variants.
Copy file name to clipboardExpand all lines: grails-doc/src/en/guide/upgrading/upgrading80x.adoc
+31-15Lines changed: 31 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -44,15 +44,18 @@ Grails 8 requires a minimum of Java 21 to both build and run Grails applications
44
44
This is an increase from Grails 7, which required Java 17.
45
45
Update your project's toolchain, CI pipelines, and deployment environments to use JDK 21 or later.
46
46
47
-
==== 2. Spring Boot 4.0.x
47
+
==== 2. Spring Boot 4.1.x
48
48
49
-
Grails 8 upgrades from Spring Boot 3.5.x to Spring Boot 4.0.x.
50
-
This is a major upgrade that brings Spring Framework 7.0.x, new module structure, and several breaking changes.
49
+
Grails 8 upgrades from Spring Boot 3.5.x to Spring Boot 4.1.x.
50
+
This crosses the Spring Boot 4 major release boundary and adopts the Spring Boot 4.1 managed stack used by Grails 8: Spring Framework 7.0.x, Spring Security 7.1.x, Spring Data 2026.0.x, Micrometer 1.17.x, Jackson 3.1.x, Tomcat 11.0.x, and Jakarta Servlet 6.1.
51
+
The upgrade includes the Spring Boot 4 module split, removed Spring Framework 6 deprecations, and additional Spring Boot 4.1 removals of APIs and properties that were deprecated in Spring Boot 4.0.
* The `grails-micronaut` plugin continues to work with Spring Boot 4's default loader.
254
257
If you experience issues running your Micronaut-enabled Grails application via `java -jar`, please report them to the https://github.com/apache/grails-core/issues[Grails issue tracker].
255
258
256
-
===== 7.2 enforcedPlatform Required for grails-bom
259
+
===== 7.2 enforcedPlatform Required for Micronaut BOMs
257
260
258
-
When using Micronaut, the `grails-bom` **must** be applied as `enforcedPlatform` instead of `platform`.
261
+
When using Micronaut, select a Micronaut-compatible Grails BOM and apply it as `enforcedPlatform` instead of `platform`.
262
+
The default choice is `grails-micronaut-bom`; Hibernate-specific variants are covered in section 7.4.
259
263
The Micronaut 5 platform declares its own managed dependency versions that conflict with those managed by the `grails-bom`.
260
264
Without `enforcedPlatform`, Gradle's default conflict resolution (highest version wins) allows the Micronaut platform to silently override `grails-bom` versions, leading to binary incompatibilities at runtime.
261
265
@@ -265,22 +269,22 @@ For example, without `enforcedPlatform`:
265
269
* **Spock** is upgraded from 2.3-groovy-4.0 to 2.4-groovy-5.0 -- compiled against Groovy 5, incompatible with Groovy 4 classes
266
270
* **Kotlin**, **Mockito**, **Byte Buddy** are upgraded to versions not tested with the Grails stack
267
271
268
-
Using `enforcedPlatform` makes all `grails-bom` constraints strictly versioned so they cannot be overridden by any transitive dependency.
272
+
Using `enforcedPlatform` makes the selected Micronaut BOM constraints strictly versioned so they cannot be overridden by any transitive dependency.
269
273
270
-
The Grails Gradle Plugin will error at configuration time if `grails-micronaut` is detected and `grails-bom` is not applied as `enforcedPlatform`.
274
+
The Grails Gradle Plugin will error at configuration time if `grails-micronaut` is detected and no Micronaut-compatible Grails BOM is applied as `enforcedPlatform`.
271
275
272
276
[source,groovy]
273
277
.build.gradle
274
278
----
275
279
dependencies {
276
280
// enforcedPlatform is required when using grails-micronaut
NOTE: Applications generated by the Grails Forge automatically use `enforcedPlatform` when the Micronaut feature is selected.
287
+
NOTE: Applications generated by the Grails Forge automatically use the appropriate Micronaut BOM as `enforcedPlatform` when the Micronaut feature is selected.
284
288
285
289
===== 7.3 Micronaut Features Require JDK 25
286
290
@@ -360,7 +364,7 @@ If you need to restore the legacy behavior temporarily, the deprecated marshalle
360
364
==== 9. Jackson 3 is the New Default
361
365
362
366
Spring Boot 4 ships Jackson 3 (`tools.jackson.*`) and auto-configures a `JsonMapper` bean instead of the Jackson 2 `ObjectMapper`.
363
-
Grails 8 follows that change: any Grails module that previously declared `com.fasterxml.jackson.core:jackson-databind` (Jackson 2) now declares `tools.jackson.core:jackson-databind` (Jackson 3, currently 3.1.0 via the Spring Boot 4 BOM).
367
+
Grails 8 follows that change: any Grails module that previously declared `com.fasterxml.jackson.core:jackson-databind` (Jackson 2) now declares `tools.jackson.core:jackson-databind` (Jackson 3.1.x via the Spring Boot 4.1 BOM).
364
368
365
369
**What stayed the same:**
366
370
@@ -400,7 +404,7 @@ Spring Boot 4 provides a `tools.jackson.databind.json.JsonMapper` bean instead o
400
404
Update injection points to expect `JsonMapper`.
401
405
402
406
**If you must stay on Jackson 2 temporarily:**
403
-
Spring Boot 4 still manages the Jackson 2 BOM (currently 2.21.2) and provides an opt-in toggle so the auto-configured mapper preserves Jackson 2 defaults:
407
+
Spring Boot 4 still manages the Jackson 2 BOM and provides an opt-in toggle so the auto-configured mapper preserves Jackson 2 defaults:
404
408
405
409
[source,yaml]
406
410
.application.yml
@@ -764,12 +768,24 @@ If your application *directly* uses `@Retryable`, `@EnableRetry`, or `@Recover`,
NOTE: The `grails-bom` pins a known-good Spring Retry version (`2.0.x`), so you do not need to specify a version when using `enforcedPlatform("org.apache.grails:grails-bom:$grailsVersion")`.
771
+
NOTE: The `grails-bom` pins a known-good Spring Retry version (`2.0.x`), so you do not need to specify a version when your build uses the Grails BOM, whether it is auto-applied by the Grails Gradle plugin or declared explicitly.
768
772
Override the BOM-managed version in your build if you need a newer release.
769
773
770
774
==== 20. Other Default Behavior Changes
771
775
772
-
Spring Boot 4 made several smaller default-behavior changes that you may notice but rarely require code changes:
776
+
Spring Boot 4.0 and 4.1 made several smaller default-behavior changes that you may notice but rarely require code changes:
777
+
778
+
* **Spring Boot 4.1 removes Spring Boot 4.0 deprecations.**
779
+
If you tested against an earlier Grails 8 snapshot or Spring Boot 4.0.x directly, remove any use of APIs, methods, or configuration properties that were only deprecated there before moving to the current Grails 8 line.
780
+
781
+
* **The Spring Boot `BuildInfo` task writes `META-INF/build-info.properties` by default.**
782
+
If your build, packaging, or tests read `build-info.properties` from the root of the generated resources directory, update them to read `META-INF/build-info.properties` or configure the task's `filename` property.
783
+
784
+
* **Spring Data JPA repository bootstrap modes were tightened.**
785
+
Grails GORM is unaffected, but applications that also use Spring Data JPA directly should review any `spring.data.jpa.repositories.bootstrap-mode` setting when moving to Spring Boot 4.1.
786
+
787
+
* **Derby support is deprecated in Spring Boot.**
788
+
Grails does not use Derby by default, but applications that added Derby through Spring Boot auto-configuration should plan a migration to H2, HSQLDB, or another supported database.
773
789
774
790
* **Logback default charset is now `UTF-8`** for log files (aligning with the existing Log4j2 default).
775
791
Console output uses `Console#charset()` if available, otherwise `UTF-8`.
0 commit comments