v2024.0.0-M2
Pre-releaseWhat's Changed
⭐️ New Features
Modularizing the codebase
Spring Boot 4 has refactored its codebase into a more modular structure, I believe this is the right direction for the future.
The Grace framework 2024 & 2025 will also start doing this. Grace's plugins will be independent, more focused, and at the same time, they will integrate better with Spring Boot's modules.
- cb0781b Create grace-boot-async module #1269
- 0fdd6c6 Create grace-boot-cache module #1208
- 993334b Create grace-boot-events module #1270
- b8c8a7f Create grace-boot-hibernate module
- 3da036b Create grace-boot-logging module #1257
- de22bbd Create grace-boot-mongodb module #1231
- 594da2a Create grace-boot-persistence module #1258
- 5fb94a5 Create grace-boot-plugin module #1259
- 7371950 Create grace-boot-rest module #1256
- a41b294 Create grace-boot-test module #1272
- ff8f98c Create grace-boot-validation module #1271
- 6e67167 Create grace-boot-web module #1207
- 8ee356f Create grace-web-rest module #1255
Core plugins have been consolidated into the framework
- 2aaa2e7 Merge grace-geb into the framework #1239
- ad6383e Merge grace-database-migration into the framework #1238
- de22bbd Merge MongoDB plugin into the framework #1232
- b8c8a7f Merge Hibernate plugin into the framework #1229
- e8ac2f0 Merge grace-views into the framework #1215
- a084193 Merge grace-scaffolding into the framework #1212
- cb424a0 Merge grace-fields into the framework #1211
- 1c80ba8 Merge grace-fields into the framework #1211
- 25ba4b3 Merge grace-cache into the framework #1209
- ce6e889 Merge grace-plugin-events into the framework
- e49b141 Merge grace-plugin-async into the framework
🐞 Bug Fixes
-
9b924d4 Fix deprecation warnings due to tasks calling getProject() at execution time #1297
-
2099e41 Fix type cast warnnings in ParameterizedGrailsUnitTest #1292
-
cea4095 Fixes the resources in the
app/*not found in development mode #1251- ResourceLocator should use
BuildSettings.GRAILS_APP_PATHinstead ofGrailsResourceUtils.GRAILS_APP_DIR
- ResourceLocator should use
-
8666cb7 Fixes errors for using
project.register(copyAstClasses)#1164
🛠 Improvements
-
08617b1 Don't include unused jars in the Shell CLI binary #1296
-
c576e84 Decouple grace-web from grace-databinding GrailsParameterMap and PropertyEditorRegistryUtils use DataBinder.DEFAULT_DATE_FORMAT
-
18de6f8 Restore grace-web-databinding module
-
807815e Remove explicit dependency on
grace-plugin-restfor grace-boot-web #1294 -
ffb12df Add explicit dependency on
grace-views-markupfor grace-boot-rest #1293 -
f954482 Provide
installandhelpcommands for fields plugin #1291 -
f3d12f9 Update StartScriptGenerator templates for Grace Shell #1290
-
279be59 Exclude the plugins that have been consolidated into framework #1288
-
12b852d Update CreateAppCommand to support creating a minimal Grace 2024.0 app #1287
-
00b9d03 Migrate to Maven Central Portal Snapshots when using SNAPSHOT version to generate new project #1286
-
8df446b Make Gradle dependencies sorted and grouped by scope and dependency #1283
-
badedbe Update autoconfigure compiler for Grace Application #1282
-
81511cb Provide install command for geb plugin to configure selenium drivers #1281
-
788f94c Add selenium api and drivers dependencies for geb plugin #1280
-
ac4403c Plugins contain scripts and templates should include these into resources when packaging #1279
- grace-plugin-database-migration
- grace-plugin-fields
- grace-plugin-geb
- grace-plugin-scaffolding
-
839ca74 Grace Boot MongoDb: add missing
grails-plugin.xml#1278 -
5b6cfbb Grace Boot Hibernate: add missing
grails-plugin.xml#1277 -
3df9acc Grace Boot Web: Remove unnecessary dependency on grace-plugin-gsp #1276
-
b51fade Grace Boot: Remove unnecessary dependency on grace-web #1275
-
722515a Cleanup dependency on grace-plugin-api #1274
- grace-core do not expose grace-plugin-api any more, so all the plugins should explicit depend on it.
- grace-web only use grace-plugin-api compileOnly now.
-
e551777 Use PropertySourcesPropertyResolver provided by Spring Framework #1273
- Don't use ConfigurationPropertySources provided by Spring Boot, because some tags do not depend on Spring Boot
-
16de4f5 Update README - Update the versions of Groovy, Gradle, Spring Boot
-
99b6884 Remove duplicated
grails.factoriesin grace-web-url-mappings #1245 -
737b52f Update
migration.gdslin the database-migration plugin #1240- Correct the
migrationDirtodb/migrations - Correct the
columnmethods definded increateTableaddColumncreateIndexinsertloadDataloadUpdateDataupdate
- Correct the
-
9226c41 Add missing 'grails.factories' for 'database-migration' plugin
-
8b9a2e0 Add missing 'grails-plugin.xml' for 'geb' plugin
-
223744d Add missing 'grails-plugin.xml' for 'database-migration' plugin
-
8c06e3a Remove unused plugins in the gradle/grails.versions.toml
-
5e96dfe Rearrange versions and libraries in the gradle/libs.versions.toml
-
aa44851 Code formatting with Checkstyle and Codenarc
-
ff8ab2e Add dependencies to Gradle Version Catalog
- Add glassfish-expressly
- Add hibernate-core
- Add spring-orm
-
d2638e2 Update Gradle Version Catalog after importing 'cache' 'fields' 'scaffolding' 'views' plugins #1219
-
05980f8 Rename the package of Grace Views #1218
- Change the package of grace-views-json from
grails.plugin.json.view=>org.grails.views.json - Change the package of grace-views-markup from
grails.plugin.markup.view=>org.grails.views.markup
- Change the package of grace-views-json from
-
1070acb Refactor Grace Json View API: Use native
groovy.json.*API instead #1217- Remove
grails.plugin.json.builder.StreamingJsonBuilder - Remove
grails.plugin.json.builder.JsonOutput - Remove
grails.plugin.json.builder.JsonGenerator - Remove
grails.plugin.json.builder.DefaultJsonGenerator - Add
grails.plugin.json.view.api.JsonWritable - Add
grails.plugin.json.util.JsonToken
- Remove
-
6f352e4 Refactor Grace Views Format Java and Groovy source and test code #1216
-
1095028 Merge grace-views into the framework #1215
- Merge grace-views-gradle into grace-gradle-plugin
- Merge grace-views-json-testing-support into grace-test-support
- Update Gradle build script
- Update ViewsTransform JsonViewsTransform MarkupViewsTransform MarkupViewTemplateEngine
- Make tests works
-
bdecfc0 Make grace-plugin-fields and grace-plugin-scaffolding works #1211 #1212
- Add grace-scaffolding-core grace-plugin-fields grace-plugin-scaffolding submodules
- Update Gradle build script
- Add
grails-plugin.xmlfor grace-plugin-fields and grace-plugin-scaffolding - Add
@TagLibtoFormFieldsTagLib - Update
ContextMarkupRendererContextMarkupRendererImplDomainMarkupRendererImplDelegatingBeanPropertyAccessorImpl - Update
DomainMarkupRendererSpecandFormFieldsTemplateServiceSpec
-
566f3d2 Make grace-cache-core and grace-plugin-cache works #1209
- Add grace-cache-core and grace-plugin-cache submodules
- Update Gradle build script
- Add grails-plugin.xml
- Add
@TagLibtograils-plugin.xml - Migrate some JUnit 4 tests to JUnit 5
- Remove demo tests
-
2aa5367 Enhance
CodeGenConfig#1201- Add method
loadDefaultConfig()to simplify usage
- Add method
-
e0f2608 Relocate
CodeGenConfigfrom grace-api to grace-bootstrap #1200 -
e166042 Rename beans to
propertySourcesPlaceholderConfigurerbeanPropertyOverrideConfigurerto keep naming consistent with theCoreConfiguration#1198 -
cf01cbf Refine GroovyPagesTemplateRenderer
- Remove unused codes
- Decouple
grace-web-gspfromgrace-plugin-domain-class
-
60e7962 Move
CamelCaseUrlConverterSpecandHyphenatedUrlConverterSpecfrom grace-core to the grace-web-common #1189 -
f39e5cf BuildSettings.APP_BASE_DIR: rename
base.dirtograils.base.dir#1186 -
e7e1257 Improve
EntityTraitInjectorandGormTransformer#1184- Refactor
EntityTraitInjectorandGormTransformer - Add tests
- Refactor
-
17e7afe Remove the configuration of system properties in
GrailsGradlePlugin.configureGrailsBuildSettings()#1173 #1157 -
7ff8e8b Update
GspCompileOptions: remove the use of deprecatedAbstractOptions#1166 #1165 -
f7e33da Enhance
FindMainClassTaskandGrailsGradlePlugin.registerFindMainClassTask()#1163 -
a7a1a54 Add
configDirtoGroovyPageForkCompileTaskAnd migrateproject.buildDirtoproject.layout.buildDirectory#1162 -
c284a33 Task
compileWebappGroovyPagesshould dependsOnclasses#1161 -
99554ca Rename
grace-gormtograce-dataproperties in the Grace BOM #1144 -
c9ff2fc Improve GroovyCompiler to allow Groovy scripts to be recompiled and reloaded after modification #1142
-
25a6b25 Ensure that Grace Artefact classes are not registered prematurely into the Spring context #1141
-
aeb8b10 Update .gitattributes to ensure the web fonts are treated as binary #1138
🎯 Refactoring
#1295 Restore grace-web-databinding module c714723
- Restore grace-web-databinding module
- Decouple grace-web from grace-databinding
- GrailsParameterMap and PropertyEditorRegistryUtils use
DataBinder.DEFAULT_DATE_FORMAT
- GrailsParameterMap and PropertyEditorRegistryUtils use
#1260 Create grace-web-rest module
- Introduce RendererRegistryCustomizer #1260
RendererRegistryCustomizerallow to customizeRendererRegistry, likeDefaultRendererRegistryCustomizer, to add more user-definedRenderer
#1254 Refactor GrailsExceptionResolver 1622cf5
- Introduce
GrailsUrlMappingsExceptionResolverto make grace-web-mvc decoupled from grace-web-url-mappings GrailsExceptionResolvershould not reuse cached controller attribute to find the given error path- Cleanup
GrailsWrappedRuntimeException
- 09ae9a3 Cleanup GrailsWrappedRuntimeException
- e663697 GrailsExceptionResolver should not reuse cached controller attribute to find the given error path
- 835e087 Introduce GrailsUrlMappingsExceptionResolver to make grace-web-mvc decoupled from grace-web-url-mappings
#1253 Refactor grace-web-url-mappings c843dd9
- Relocate CORS related to grace-plugin-url-mappings
- Remove method
setGrailsCorsConfiguration()inUrlMappingsHandlerMapping, useAbstractHandlerMapping.setCorsConfigurations()instead - Relocate
UrlMappingsErrorPageCustomizerandAnsiConsoleUrlMappingsRendererSpecto grace-plugin-url-mappings
- 4b83e7c Relocate CORS related to grace-plugin-url-mappings Remove method
setGrailsCorsConfiguration()inUrlMappingsHandlerMapping, useAbstractHandlerMapping.setCorsConfigurations()instead - 5f7f4df Relocate UrlMappingsErrorPageCustomizer
- 6ff146e Relocate AnsiConsoleUrlMappingsRendererSpec
#1252 Various improvements related to stack trace logging and exception display 98e54e7
- ErrorsViewStackTracePrinter should use
grailsResourceLocatorfirst - And
grailsResourceLocatorneed to setsearchLocationtoBuildSettings.BASE_DIR - Display the relative path of the file associated with the errors
- Auto-configure StackTraceFilterer bean on GrailsExceptionResolver
- Improve the log messages of exception's stack trace
- Fixed StackTracePrinterSpec
- Add an additional Spring configuration metadata:
grails.full.stacktrace - Formatting request parameters and log information, the excluded parameters will be marked [FILTERED] in the log
- 08b15d9 Fixed GrailsExceptionResolverTests
- dca3b58 Formatting request parameters and log information The excluded parameters will be marked [FILTERED] in the log.
- 88b8535 Add an additional Spring configuration metadata:
grails.full.stacktrace - 58c182d Fixed StackTracePrinterSpec
- 43bf97b Improve the log messages of exception's stack trace
- 22e53a9 Display the relative path of the file associated with the errors
- 1f72a6f Auto-configure StackTraceFilterer bean on GrailsExceptionResolver
- e9895d2 ErrorsViewStackTracePrinter should use
grailsResourceLocatorfirst AndgrailsResourceLocatorneed to setsearchLocationtoBuildSettings.BASE_DIR
#1250 Create grace-plugin-taglibs 5057f8f
- 7dc73ae Create grace-plugin-taglibs Move
org/grails/plugins/web/taglib/*TagLibfrom grace-plugin-gsp to grace-plugin-taglibs #1249
#1248 Consolidate 'grace-web-sitemesh' into 'grace-web-gsp' 7457d09
- c8ee8a5 Consolidate 'grace-web-sitemesh' into 'grace-web-gsp'
#1247 Make 'grace-web-mvc' decoupled from 'grace-web-sitemesh' efc9af4
- 44fc005 Make 'grace-web-mvc' decoupled from 'grace-web-sitemesh'
- a6908f4 Update copyright year to 2025
- 87dcb0b Remove 'grace-web-common' module #1246
#1246 Consolidate 'grace-web-common' into 'grace-web' 3fdd3e0
- f45f130 Consolidate 'grace-web-common' into 'grace-web'
#1245 Relocate AnsiConsoleUrlMappingsRenderer UrlMappingsReportCommand from grace-web-url-mappings to grace-plugin-url-mappings 760c80f
- 686548f Relocate
AnsiConsoleUrlMappingsRendererUrlMappingsReportCommandfrom grace-web-url-mappings to grace-plugin-url-mappings
#1244 Consolidate 'grace-web-databinding' into 'grace-web-common' a8f066d
- f030aa0 Consolidate 'grace-web-databinding' into 'grace-web-common'
- Move
DataBinderWebDataBindingWebDataBindingTraitInjectorfrom 'grace-web-databinding' to 'grace-plugin-databinding' - Move
org/grails/web/databinding/*from 'grace-web-databinding' to 'grace-web-common'
- Move
#1243 Consolidate 'grace-web-jsp' into 'grace-web-gsp' 9663510
- b423a3f Consolidate 'grace-web-jsp' into 'grace-web-gsp'
#1242 Cleanup dependencies 4143506
Relocate ErrorsViewStackTracePrinter GrailsWrappedRuntimeException from grace-web-common to grace-web-mvc
Remove getPagesTemplateEngine() of GrailsApplicationAttributes
Update dependencies
grace-web-gspno longer depends ongrace-web-taglibgrace-web-commonno longer depends ongrace-gspgrace-plugin-fieldsshould depends ongrace-web-taglib
#1241 'grace-web-gsp-taglib' has been consolidated into 'grace-web-taglib' and 'grace-plugin-gsp' e28ab80
- 1c31338 Remove
grace-web-gsp-taglibmodule its functionality has been consolidated intograce-web-taglibandgrace-plugin-gsp - 960c49c Relocate
org/grails/plugins/web/taglib/*fromgrace-web-gsp-taglibtograce-plugin-gsp - 0b64c4b Relocate
StandaloneTagLibraryLookupfromgrace-web-gsp-taglibtograce-web-taglib
#1205 Refactor GrailsApplicationLifeCycle 29476e5
- 8d7161d
- Rename GrailsApplicationLifeCycle to GrailsApplicationLifecycle
- Rewrite GrailsApplicationLifecycle using Java
- Remove GrailsApplicationLifeCycleAdapter
- Simplify Plugin
- Rename
GrailsApplicationPostProcessor.setGrailsApplicationLifeCycle()toGrailsApplicationPostProcessor.setGrailsApplicationLifecycle() - Update GrailsApplicationBuilder
#1204 Refactor Grace Spring Boot and Grace Spring e3af96e
- f24e041 Move all classes in the grace-spring-boot into grace-spring
The grace-spring-boot module contains some classes related to the Spring framework and Spring Boot,
But now, all of theme have been relocated into grace-spring,
you should use grace-spring directly.
#1203 Refactor Grace Bootstrap b3c3975
Move the classes under the org.grails.config package from grace-core and grace-spring-boot to grace-bootstrap
Move NavigableMap NavigableMapConfig from grace-api to grace-bootstrap
Move ConfigProperties ConfigPropertiesSpec from grace-plugin-core to grace-bootstrap
Rename GroovyConfigPropertySourceLoader YamlPropertySourceLoader package from org.grails.spring.boot.env to org.grails.config.loader
-
ef0eab9 Move
ConfigPropertiesConfigPropertiesSpecfrom grace-plugin-core to grace-bootstrap -
- Move
NavigableMapNavigableMapConfigfrom grace-api to grace-bootstrap - Move
ConfigMapSpecNavigableMapSpecfrom grace-api to grace-bootstrap
- Move
-
- Rename
GroovyConfigPropertySourceLoaderYamlPropertySourceLoaderpackage fromorg.grails.spring.boot.envtoorg.grails.config.loader - Rename package
GroovyConfigPropertySourceLoaderSpecYamlPropertySourceLoaderSpec - Update
grace-plugin-core/src/main/resources/META-INF/spring.factories
- Rename
-
- Move the classes under the
org.grails.configpackage from grace-core and grace-spring-boot to grace-bootstrap - Move
CompositeConfigEnvironmentAwarePropertySourceNavigableMapPropertySourcePrefixedConfigPrefixedMapPropertySourcePropertySourcesConfigfrom grace-core to grace-bootstrap - Move
NavigableMapNestedEqualitySpecNavigableMapPropertySourceSpecNavigableMapSpringProfilesSpecPropertyResolutionSpecPropertySourceConfigSpecPropertySourcesConfigSpecSystemEnvironmentConfigSpecfrom grace-core to grace-bootstrap - Move
GroovyConfigPropertySourceLoaderYamlPropertySourceLoaderfrom grace-spring-boot to grace-bootstrap - Move
GroovyConfigPropertySourceLoaderSpecYamlPropertySourceLoaderSpecfrom grace-spring-boot to grace-bootstrap
- Move the classes under the
#1202 Relocate Named and Described from grace-bootstrap to grace-api 7dd3a32
#1199 Refactor GrailsApplication 598ffab
-
b903934 Fix doc typos
-
ca81030 Remove method
getMetadata()in GrailsApplicationGrailsApplicationshould not depend onMetadata, please useMetadata.getCurrent()instead -
0b1c423 Remove deprecated constants in GrailsApplication
- CONFIG_CLASS
- DATA_SOURCE_CLASS
- PROJECT_META_FILE
#1197 Revisit Grace Spring Boot Module 3976243
Move some classes to more appropriate modules
- 7ba56be Relocate
GroovyConfigPropertySourceLoaderSpecYamlPropertySourceLoaderSpectograce-spring-boot/src/test/groovy/org/grails/spring/boot/env/ - 117aa7d Relocate
ClassEditorPropertiesEditortograce-spring-boot/src/main/groovy/org/grails/spring/beans/support/ - 040d93f Move
ClassRelativeClassLoaderClassRelativeResourcePatternResolverfrom grace-spring-boot to grace-plugin-i18n - be716c4 Move
GrailsPlaceholderConfigurerGrailsBeanPropertyOverrideConfigurerfrom grace-spring-boot to grace-plugin-core - 803a60f Move
NavigableMapPropertySourceNavigableMapPropertySourceSpecfrom grace-api to grace-spring-boot
#1196 Refactor IOUtils 1711f51
- ead6279 Refactor IOUtils Remove SpringIOUtils
- Using IOUtils instead Deprecated IOUtils.toString(Reader)
- Using IOUtils.copyToString(Reader)
- Enhance IOUtils.copy() methods
- Using FileCopyUtils.copy() to implement
#1195 Migrate to Spring Framework's Resource API 1d34cd4
-
d18a2b9 Use
PathMatchingResourcePatternResolverinstead ofCachingPathMatchingResourcePatternResolver -
50cce34 Move
ResourceLocatorfrom grace-api to the grace-core- Move
DefaultResourceLocatorfrom grace-plugin-api to the grace-core - Remove
org.grails.coreio.PluginPathAwareFileSystemResourceLoader
- Move
-
2a67789 Use
StaticResourceLoaderin the grace-bootstrap -
bfec5ab Use built-in classes such as Resource ResourceLoader provided by the Spring framework
The following classes have been removed
- AbstractFileResolvingResource
- AntPathMatcher
- ByteArrayResource
- ClassPathResource
- DefaultResourceLoader
- FileSystemResource
- FileSystemResourceLoader
- GrailsByteArrayResource
- GrailsResource
- PathMatchingResourcePatternResolver
- Resource
- ResourceLoader
- SpringResource
- UrlResource
#1194 Refactor Grace API f09d429
-
ff0729e Move
MixinMixinTargetAwarefrom grace-api to grace-core
MoveCacheEntryPairTriplefrom grace-api to grace-util
MoveAbstractTypeConvertingMapTypeConvertingMapTypeConvertingMapTestsfrom grace-api to grace-util -
- Move
CompositeConfigEnvironmentAwarePropertySourcePrefixedConfigPrefixedMapPropertySourcePropertySourcesConfigfrom grace-api to the grace-core - Move
NavigableMapPropertySourceSpecfrom grace-core to grace-api - Move
DefaultGrailsPluginTestsfrom grace-plugin-api to grace-test-suite-uber
- Move
-
- Move
DefaultErrorsPrinterfrom grace-api to the grace-core - Rename
NewInstanceCreationExceptiontoGrailsClassCreationExceptionand relocate to grace-core - Rename
GrailsDomainExceptiontoGrailsClassExceptionand relocate to grace-core - Rename
InvalidPropertyExceptiontoGrailsPropertyInvalidExceptionand relocate to grace-core
- Move
-
- Move
AbstractGrailsClassAbstractInjectableGrailsClassfrom grace-api to the grace-core - Move
InvalidVersionExceptionVersionComparatorGrailsPluginPluginSourcefrom grace-api to the grace-plugin-api
- Move
-
aeb674b Move
ConfigPropertiesfrom grace-api to the grace-plugin-core -
784c2d3 Move
GrailsFactoriesLoaderfrom grace-api to the grace-bootstrap -
42b116b Move
Settingsfrom grace-api to the grace-bootstrap
#1193 Refactor GSP plugin 6a440fc
- 2c8e8ea Remove deprecated
GrailsTagLibClassDefaultGrailsTagLibClassTagLibArtefactHandler - ae9039a Make
ControllerTagLibraryTraitInjectorinherit directly fromTraitInjectorAdapter - 1514bd3 Use
ArtefactTypes.TAG_LIBRARYinstead ofTagLibArtefactHandler.TYPE
#1192 Refactor Bootstrap Artefact 0ae405b
-
30ababb Relocate
BootstrapArtefactHandlerBootstrapArtefactHandlerSpecto grace-boot- Move
GrailsBootstrapClassDefaultGrailsBootstrapClassfrom grace-web to grace-boot - Update
GrailsApplicationBuilder
- Move
-
2c585fe Auto-configure
BootstrapClassRunner- Move
BootstrapClassRunnerfrom grace-plugin-controllers to grace-boot - Rename
BootstrapClassRunnertoGrailsBootstrapClassRunner - Auto-configure
GrailsBootstrapClassRunnerin GrailsBootstrapAutoConfiguration - Add
grails.bootstrap.skipto Spring Configuration Metadata
- Move
-
7d7a392 Use
ArtefactTypes.BOOTSTRAPinstead ofBootstrapArtefactHandler.TYPE
#1191 Refactor Grace Boot 86e998f
- d1cccad Refactor Grace Boot
- Move
ApplicationArtefactHandlerApplicationClassInjectorfrom grace-core to grace-boot - Move
LoggingTransformerSpecfrom grace-logging to grace-boot - Update
ArtefactTypeAstTransformationSpecGlobalGrailsClassInjectorTransformationSpecGrailsAwareInjectionOperationSpec
- Move
#1190 Refactor Services plugin 907ece2
- df08a97 Refactor Services plugin
- Use
ArtefactTypes.SERVICEinstead ofServiceArtefactHandler.TYPE - Move
GrailsServiceClassDefaultGrailsServiceClassfrom grace-core to grace-plugin-services - Relocate
ServiceArtefactHandlerServiceArtefactHandlerSpecto grace-plugin-services - Update
ServiceUnitTest
- Use
#1189 Refactor Controllers and Controllers plugins ba72157
-
50ba03c Move
DefaultGrailsControllerClassSpecto the grace-plugin-controllers -
d053ffb Refactor UrlMappings plugin
- Use
ArtefactTypes.URL_MAPPINGSinstead ofUrlMappingsArtefactHandler.TYPE - Move
GrailsUrlMappingsClassDefaultGrailsUrlMappingsClassfrom grace-core to grace-web-common - Relocate
UrlMappingsArtefactHandlerUrlMappingsArtefactHandlerSpecto grace-plugin-url-mappings
- Use
-
cb14e53 Refactor Controllers plugin
- Use
ArtefactTypes.CONTROLLERinstead ofControllerArtefactHandler.TYPE - Move
ActionCamelCaseUrlConverterHyphenatedUrlConverterUrlConverterfrom grace-core to grace-web-common - Relocate
ControllerArtefactHandlerControllerArtefactHandlerSpecto grace-plugin-controllers - Update
LoggingTransformerSpecin grace-logging - Add
ControllerLoggingTransformerSpecto grace-plugin-controllers
- Use
#1188 Refactor Domain Class plugin eb281db
- 38d8a3c Relocate
DomainClassArtefactHandlerto grace-plugin-domain-class - 77b08ec Decouple
DefaultGrailsApplication.addArtefact()fromDomainClassArtefactHandler - 8c0bfeb Introduce ArtefactTypes - Use
ArtefactTypes.DOMAIN_CLASSinstead ofDomainClassArtefactHandler.TYPE - ff33e4e Use
GrailsASTUtils.isDomainClass()instead ofDomainClassArtefactHandler.isDomainClass()
#1187 Refactor Domain Class plugin 8fb1916
- cafca11 Remove
AnnotationDomainClassArtefactHandler - 54f732a Relocate
DefaultGrailsDomainClassInjectorto grace-plugin-domain-class
#1185 Refactor Domain Class plugin ac7f0ac
- 2c627bc Decouple
grace-corefromgrace-plugin-domain-class- Update tests
- Move tests from
grace-coreintograce-plugin-domain-class
#1183 Merge async and events plugins into the framework 8d780cc
- ccca4bf Code format
- 35eef92 Build async and events plugins
- Add grace-plugin-async and grace-plugin-events
- Use Gradle version catalog to manage dependencies
- Add version and descriptor to plugins
- Update TransactionalPromiseDecorator and make tests pass
#1182 Restructure GORM Support 8853c8c
- 0d901fa Move ProxyHandler and PersistenceContextInterceptor to
grace-datastore-gorm-supportSee graceframework/grace-data#73 - 74555e5 Add
EntityTraitInjectorandGormTransformerfromgrace-datastore-gorm-supportSee graceframework/grace-data#73
#1180 Refactor Gradle Doc Plugin 3f68dc3
-
50977dc Refactor DocPublisher
- Rename
publishPdf()togeneratePdfGuide() - Remove
PublishPdfTask
- Rename
-
4b19463 Refactor GrailsDocGradlePlugin
- Rename
docstopublishGuide - Add new properties
singlePdfgeneratePdftoPublishGuideTask - Remove registed task
docsPdf
- Rename
#1176 Refactor Gradle Doc Plugin a7386c2
- b047043 Remove obsolete MigrateLegacyDocs
- 4be1766 Refactor PublishGuideTask - Migrate all properties to lazy properties
- cc876a3 Refactor PublishGuideTask Remove Gradle's deprecation warning "Invocation of Task.project at execution time has been deprecated."
#1175 Refactor Grace Banner 8b4f907
-
205a718 Refactor GrailsResourceBanner
- Align with Spring Boot's
ResourceBanner - Don't return the default application name in
Metadata.getApplicationName() - Add GrailsResourceBannerTests
- Align with Spring Boot's
-
efe2899 Refactor GrailsResourceBanner
- Remove deprecated method
getApplicationVersion(Class<?> sourceClass) - Get name and version from environment
- Remove deprecated method
#1174 Refactor Gradle plugins 3c7f267
-
edc3a51 Refactor GrailsGradlePlugin
- Remove
enableNative2Ascii()in favor of using Gradle'sProcessResources - Deprecated
native2asciiandnative2asciiAntinGrailsExtension
- Remove
-
b4a4643 Refine GrailsPluginGradlePlugin
- Add
ProcessPluginResourcesTask - Improve
configurePluginResources()
- Add
-
dc80af8 Refine GrailsGradlePlugin and GrailsWebGradlePlugin
- Add
configureProcessResources()forGrailsWebGradlePlugin - Extract copying templates from
GrailsGradlePlugin.enableNative2Ascii()toGrailsWebGradlePlugin
- Add
#1172 Refactor Gradle Profile Plugin 8008127
-
8f89eb1 Refactor GrailsProfileGradlePlugin
- Add constants
PROCESS_PROFILE_RESOURCES_TASK_NAMECOMPILE_PROFILE_TASK_NAMEPROFILE_GROUP - Add
registerOrGetJarTask()andregisterOrGetSourcesJarTask() - Improve
sourcesJarTask
- Add constants
-
4a39330 Refactor GrailsProfileGradlePlugin
- Add
ProfileResourcesProcessTask - Improve
ProfileCompilerTask - Refactor
GrailsProfileGradlePlugin
- Add
#1171 Support configuration of project resources and sources directories 5821a9c
- 8746471 Configure the main sources and resources directories This PR allow developers to configure the app sources and resources,
grails {
appSourceDirs += ['models', 'repositories']
appResourceDirs += ['config']
}
#1170 Customize Groovy compiler configuration 4a64a9e
- 991d10b Support adding user defined node metadata This PR allow develpers to add some user defined node metadata by configuring
configScript.metaDataMap,
configScript {
metaDataMap['APP_THEME'] = 'custom meta data'
}
- 949d829 Allow to provide a custom Groovy script file that configures the Groovy compiler The default Groovy script file should be placed in
config/groovy/compiler.groov,
withConfig(configuration) {
inline(phase: 'CONVERSION') { source, context, classNode ->
source.ast.putNodeMetaData('PROJECT_NAME', '${PROJECT_NAME}')
source.ast.putNodeMetaData('PROJECT_TYPE', '${PROJECT_TYPE}')
source.ast.putNodeMetaData('PROJECT_VERSION', '${PROJECT_VERSION}')
source.ast.putNodeMetaData('PROJECT_DIR', '${PROJECT_DIR}')
source.ast.putNodeMetaData('GRAILS_APP_DIR', '${GRAILS_APP_DIR}')
}
}
#1169 Refactor Gradle plugins eb884d5
-
7d686e4 Refactor GrailsGradlePlugin
- Introduce
GenerateBuildInfo - Remove
@CompileDynamiconcreateBuildPropertiesTask()
- Introduce
-
4aba8f5 Refactor GrailsGradlePlugin
- Introduce
GenerateConfigScript - Rename
configureGroovyASTMetadata()toconfigureGroovyCompiler()
- Introduce
#1168 Refactor Gradle plugins 3b4ba01
- e775f01 Configure the classpath of the Spring Boot's BootArchive
- cf8fb3a Change the generated gsp class name: remove the prefixed 'gsp', and append '_' before the view names
- 31817da Change the compiled gsp classes target directory
- 1fb9311 Correct the Groovy build classes dirs
#1167 Refactor Gradle plugins e844d7e
-
76633b6 Improve GroovyPagePlugin and GroovyPageForkCompileTask
- Remove unnecessary dependency on
jakarta.servlet-api - Remove Configuration
providedCompile, only usecompileClasspath - Don't call
Task.getProject()from a task action - Use
JavaPlugin.CLASSES_TASK_NAMEinstead ofclasses - Use
GrailsGradlePlugin.GRAILS_EXTENSION_NAME
- Remove unnecessary dependency on
-
dbe50eb Refactor GrailsProfileGradlePlugin
- Use
BasePlugin.ASSEMBLE_TASK_NAMEinstead ofassemble - Rename
CONFIGURATION_NAMEtoGRAILS_CONFIGURATION_NAME - Rename
RUNTIME_CONFIGURATIONtoPROFILE_CONFIGURATION_NAME - Use Groovy style
project.configurationsandproject.extensions
- Use
-
9cdf38f Update ApplicationContextCommandTask and ApplicationContextScriptTask
- Remove
dependsOnof the tasksApplicationContextCommandTaskandApplicationContextScriptTask - Configure
dependsOnwhen registering the tasks
- Remove
-
5011c46 Refactor
GrailsGradlePlugin- Use
JavaPlugin.CLASSES_TASK_NAMEinstead ofclasses - Use Groovy style
project.configurationsandproject.extensions - Add
GRAILS_EXTENSION_NAMEFIND_MAIN_CLASS_TASK_NAMEBUILD_PROPERTIES_TASK_NAME - Rename
CONSOLE_CONFIGURATIONtoCONSOLE_CONFIGURATION_NAME - Rename
PROFILE_CONFIGURATIONtoPROFILE_CONFIGURATION_NAME - Remove
addDefaultProfile()
- Use
#1164 Refactor Gradle Plugins cd3486d
-
383a6be Improve
GrailsPluginGradlePlugin- Use constant name of the Task and Configuration
- Use
tasks.register()instead oftasks.create() - Cleanup codes
-
d5de8f5 Configure the main application class name fo
runScripttask -
bbf1781 refactor
configureGrailsBuildSettings()andconfigureSpringBootExtension()- Change
configureGrailsBuildSettings()return tovoid - Migrate deprecated
project.buildDir - Add helper methods to
SourceSets
- Change
-
85c0691 refactor
configurePathingJar- Enhance
buildClasspath() - Use
project.layout.buildDirectoryinstead ofproject.buildDir - Make
resolveClassesDirs()private
- Enhance
-
979f6c6 refactor
enableNative2Ascii()- Use inline
ant.native2ascii() - Remove
createNative2AsciiTask
- Use inline
-
ff169eb refactor
createBuildPropertiesTask()- Change its return type to
void - Use
tasks.register()instead oftasks.create() - Make build properties ordered
- Change its return type to
-
1b8aa4b refactor
configureConsoleTask()- Remove
createConsoleTask()andcreateShellTask - Use
tasks.register()instead oftasks.create()
- Remove
-
b544809 refactor
configureApplicationCommands()- Use
tasks.register()instead oftasks.create() - Remove unnecessary
@CompileDynamic
- Use
-
1e45f77 refactor
configureRunScript()andconfigureRunCommand()- Use
tasks.register()instead oftasks.create() - Remove unnecessary
@CompileDynamic
- Use
-
eb83712 refactor
configureGroovyASTMetadata()- Use
tasks.register()instead oftasks.create() - Use
tasks.named()instead oftasks.getByName() - Remove unnecessary
@CompileDynamic
- Use
#1157 Allow developers to customize the app directory 2ee497b
Grails employs a structured directory layout that organizes files and folders based on their functionality, which is essential for maintaining code in a large application.
The app directory is central to a Grails application, containing subdirectories for domains, services, views, controllers, taglibs and assets, which follow the MVC architectural pattern.
In the past, Grails has always adhered to the convention of using grails-app as a fixed directory since its inception. In Grace, we can use grails-app, or the more concise app.
Now, in the upcoming Grace 2024 version, we take it a step further by allowing developers to customize this directory. You are free to choose a more suitable specific directory, such as web, admin, api, or store.
#1149 Application type artifacts are supported in both the app/boot and src/main directories 5b594a8
- 5bf8c08
Applicationtype artifacts are supported in both theapp/bootandsrc/maindirectories- Move from
app/inittoapp/boot - Update releated tests
- Move from
#1148 Move artefact Bootstrap.groovy from app\init to app\boot 09ab913
#1147 Rename artefact type BootStrap to Bootstrap e1b61a4
- 512f9d6 Rename
BootStrap.groovytoBootstrap.groovy- Update
DefaultGrailsBootstrapClass.BOOT_STRAPtoBootstrapas the trailing part of the Bootstrap class type - Rename
BootStrapClassRunnertoBootstrapClassRunner - Change the bean name to
bootstrapClassRunnerinControllersGrailsPlugin - Update the other related tests
- We should also update the
baseprofile
- Update
#1140 Refactor GroovyCompiler ae3ef71
Only use Groovy Grape's runtime dependencies to load ArtefactHandler ClassInjector TraitInjector, so the Shell no longer need grace-plugin-controllers grace-plugin-gsp grace-plugin-url-mappings, which greatly reduces the size of the final CLI installation package.
- Introduce GrailsArtefactClassTransformation
- Remove some runtime dependencies of grace-shell
- Add support methods in TraitInjectionUtils
- Cleanup ExtendedGroovyClassLoader
#1136 Refactor the core API of the framework b0d5f75
This is a very important code refactoring and update for the framework.
Initially, I intended to run a Single-File Application Groovy script in the CLI, but after analyzing a lot of the framework's underlying code, I found that these core API were very difficult to extend and test, so I began a painful code refactoring journey.
After the refactoring, it has now become possible to successfully run a Single-File Application Groovy script in the CLI.
Refactoring involves several important APIs of Grails. I believe that refactoring these classes is significant for the maintenance and updating of the framework, and it is also very helpful for third-party plugin developers, making plugins and libraries easy to extend and test.
- ArtefactHandler
- ClassInjector
- TraitInjector
- GlobalGrailsClassInjectorTransformation
- GlobalGrailsPluginTransformation
- GrailsASTUtils
- GrailsGradlePlugin
ArtefactHandler
- Relocate ArtefactHandlerAdapter to grace-core
- Support Grails and GORM Entity for DomainClassArtefactHandler.isArtefactClass
- Refactor
isDomainClass()in DomainClassArtefactHandler - Refactor ControllerArtefactHandler
- Refactor TagLibArtefactHandler
- Support taglib with annotation
@TagLibfor TagLibArtefactHandler - Remove supports for
@TagLibraryas artefact type, use@TagLibinstead - Adding Spock tests for ArtefactHandlers
- Adding
@Artefact()annotation to Grails artefacts in the tests
ClassInjector
- Refactor ClassInjector
- Add support for ClassInjector ordering
- Using GrailsFactoriesLoader to load ClassInjector
- Update BootInitializerClassInjector
- Refactor ApplicationClassInjector
- Refactor DefaultGrailsDomainClassInjector
- Refactor AbstractGrailsArtefactTransformer
- Refactor ArtefactTypeAstTransformation
- Refactor ControllerActionTransformer
- Refactor ControllerDomainTransformer
- Refactor LoggingTransformer
- Refactor ResourceTransform
- Refactor TagLibraryTransformer
- Deprecated SupportsClassNode
- Deprecated
ClassInjector.shouldInject(URL), in favor ofshouldInject(ClassNode)
TraitInjector
- Introduce TraitInjectorAdapter
- Using
boolean supports(ClassNode)to check if the classNode need to be injected - Add support for TraitInjector ordering
- Refactor TraitInjectionUtils
- Deprecated TraitInjectionSupport
- Deprecated GlobalClassInjector and GlobalClassInjectorAdapter
GrailsASTUtils
- Adding more methods to check whether the specified source is a Grails project source
- Adding method
getGrailsArtefactType()to GrailsASTUtils - Refactor
isDomainClass()in GrailsASTUtils
GrailsGradlePlugin: configure Groovy AST Metadata for configurationScript of GroovyCompileOptions
- GRAILS_APP_DIR
- PROJECT_DIR
- PROJECT_NAME
- PROJECT_TYPE
- PROJECT_VERSION
GlobalGrailsClassInjectorTransformation and GlobalGrailsPluginTransformation
- Refactor GlobalGrailsClassInjectorTransformation
- Refine GlobalGrailsPluginTransformation
- Update GlobalGrailsPluginTransformationSpec
Grails with Spring Boot DevTools
- Initial integration of Grails with Spring Boot DevTools
- Add GrailsSourceCompiler
- Remove deprecated DirectoryWatcher related
RunCommand
- Initial support Grails Single File Application running in CLI
- Allow Grails load the specified primary sources
- Add GrailsGormCompilerAutoConfiguration
- Update GroovyCompiler
- Update GrailsApplicationCompilerAutoConfiguration
🚀 Dependency Upgrades
- f497f2b Upgrade to AspectJ 1.9.25.1 #1261
- ce3d74c Upgrade to AspectJ 1.9.25 #1233
- f4cef73 Upgrade to Eclipse Expressly 5.0.0 #121
- 7e00afb Upgrade to Geb 8.0.1 #1268
- 8954d83 Upgrade to Grace Asset Pipeline Plugin 7.0.0-M2 #1289
- 2b4b284 Upgrade to Grace Asset Pipeline Plugin 7.0.0-M1 #1115
- 4de0a48 Upgrade to Grace Async 7.0.0-M1 #1116
- bac34df Upgrade to Grace Data 2024.0.0-M1 #1118
- 3c7bd40 Upgrade to Grace Data Hibernate 2024.0.0-M1 #1119
- c1c6d1d Upgrade to Grace Data MongoDB 2024.0.0-M1 #1120
- 69c4ab8 Upgrade to Grace Doc Engine 2.0.0-M1 #1143
- de7d6c7 Upgrade to Grace Events 7.0.0-M1 #1122
- 5d18b64 Upgrade to Gradle 8.14.3 #1127
- 4882583 Upgrade to Gradle Codenarc plugin 3.6.0 #1222
- a0f5d80 Upgrade to Gradle Checkstyle plugin 10.26.1 #1221
- b1369f6 Upgrade to Gradle JaCoCo plugin 0.8.13 #1223
- 251aa04 Upgrade to Gradle Plugin Publish Plugin 2.0.0 #1284
- c74424d Upgrade to Gradle Tooling API 8.14.3 #1128 #1127
- 3f1b840 Upgrade to Groovy 4.0.29 #1227
- a262a6b Upgrade to Groovy 4.0.28 #1134
- f555f1c Upgrade to Jackson Databind 2.18.5 #1234
- 8f8e9b7 Upgrade to Jakarta Expression Language 5.0.1 #1181
- b027fb4 Upgrade to Maven 3.9.12 #1262
- 1bdd5e8 Upgrade to Maven 3.9.11 #1129
- b03aec6 Upgrade to Maven Resolver 1.9.25 #1263
- 36437c1 Upgrade to Maven Resolver 1.9.24 #1130
- a857e9a Upgrade to RxJava 3.1.12 #1228
- da5a43a Upgrade to RxJava 3.1.11 #1146
- 9655e7b Upgrade to Spring Boot 3.4.13 #1265
- b9feb31 Upgrade to Spring Boot 3.4.12 #1235
- 7a7ecd4 Upgrade to Spring Boot 3.4.11 #1224
- 657701f Upgrade to Spring Boot 3.4.10 #1177
- 9fe8457 Upgrade to Spring Boot 3.4.9 #1158
- 311fee5 Upgrade to Spring Boot 3.4.8 #1131
- c7206a7 Upgrade to Spring Framework 6.2.15 #1266
- 161206c Upgrade to Spring Framework 6.2.14 #1236
- 7e06da5 Upgrade to Spring Framework 6.2.12 #1225
- 17fc9d2 Upgrade to Spring Framework 6.2.11 #1178
- c07fd46 Upgrade to Spring Framework 6.2.10 #1159
- 46a7657 Upgrade to Spring Framework 6.2.9 #1132
- 969660b Upgrade to Tomcat 10.1.50 #1267
- 4696aed Upgrade to Tomcat 10.1.49 #1237
- f63dd0e Upgrade to Tomcat 10.1.48 #1226
- b06ff21 Upgrade to Tomcat 10.1.46 #1179
- d18443d Upgrade to Tomcat 10.1.44 #1160
- 9494134 Upgrade to Tomcat 10.1.43 #1133
⚙️ Tasks
- e696d68 Bump gradle/actions from 4.0.0 to 4.4.2
- 0a6ce4a Bump actions/checkout from 4 to 5
- 5cfc699 Update GitHub workflows - Switch to 2024.0.x
- 5815eee Next development version: 2024.0.0-SNAPSHOT
🍀 Grace Projects
- Grace Asset Pipeline v7.0.0-M2
- Grace Asset Pipeline v7.0.0-M1
- Grace Async v7.0.0-M1
- Grace Events v7.0.0-M1
- Grace Data v2024.0.0-M1
- Grace Data Hibernate v2024.0.0-M1
- Grace Data MongoDB v2024.0.0-M1
- Grace Doc Engine v2.0.0-M1
📜 Grace Profiles
- Base v2024.0.0-M1
- Plugin v2024.0.0-M1
- Profile v2024.0.0-M1
- REST API v2024.0.0-M1
- Starter v2024.0.0-M1
- Web v2024.0.0-M1
- Web Plugin v2024.0.0-M1
Full Changelog: v2024.0.0-M1...v2024.0.0-M2