Grace v2024.0.0-M2 released #1298
rainboyan
announced in
Announcements
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
What'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.
Core plugins have been consolidated into the framework
🐞 Bug Fixes
9b924d4 Fix deprecation warnings due to tasks calling getProject() at execution time Fix deprecation warnings due to tasks calling getProject() at execution time #1297
2099e41 Fix type cast warnnings in ParameterizedGrailsUnitTest Fix type cast warnnings in ParameterizedGrailsUnitTest #1292
cea4095 Fixes the resources in the
app/*not found in development mode Resources in theapp/*not found in development mode #1251BuildSettings.GRAILS_APP_PATHinstead ofGrailsResourceUtils.GRAILS_APP_DIR8666cb7 Fixes errors for using
project.register(copyAstClasses)Refactor Gradle plugins #1164🛠 Improvements
08617b1 Don't include unused jars in the Shell CLI binary 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 Remove explicit dependency ongrace-plugin-restfor grace-boot-web #1294ffb12df Add explicit dependency on
grace-views-markupfor grace-boot-rest Add explicit dependency ongrace-views-markupfor grace-boot-rest #1293f954482 Provide
installandhelpcommands for fields plugin Provideinstallandhelpcommands for fields plugin #1291f3d12f9 Update StartScriptGenerator templates for Grace Shell Update StartScriptGenerator templates for Grace Shell #1290
279be59 Exclude the plugins that have been consolidated into framework Exclude the plugins that have been consolidated into framework #1288
12b852d Update CreateAppCommand to support creating a minimal Grace 2024.0 app 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 Migrate to Maven Central Portal Snapshots when using SNAPSHOT version to generate new project #1286
686e5d7 Provide
org.graceframework.grace-appplugin Provideorg.graceframework.grace-appplugin #12858df446b Make Gradle dependencies sorted and grouped by scope and dependency Make Gradle dependencies sorted and grouped by scope and dependency #1283
badedbe Update autoconfigure compiler for Grace Application Update autoconfigure compiler for Grace Application #1282
81511cb Provide install command for geb plugin to configure selenium drivers Provide install command for geb plugin #1281
788f94c Add selenium api and drivers dependencies for geb plugin Add selenium api and drivers dependencies for geb plugin #1280
ac4403c Plugins contain scripts and templates should include these into resources when packaging Plugins contain scripts and templates should include these into resources when packaging #1279
839ca74 Grace Boot MongoDb: add missing
grails-plugin.xmlGrace Boot MongoDb: add missinggrails-plugin.xml#12785b6cfbb Grace Boot Hibernate: add missing
grails-plugin.xmlGrace Boot Hibernate: add missinggrails-plugin.xml#12773df9acc Grace Boot Web: Remove unnecessary dependency on grace-plugin-gsp Grace Boot Web: Remove unnecessary dependency on grace-plugin-gsp #1276
b51fade Grace Boot: Remove unnecessary dependency on grace-web Grace Boot: Remove unnecessary dependency on grace-web #1275
722515a Cleanup dependency on grace-plugin-api Cleanup dependency on grace-plugin-api #1274
e551777 Use PropertySourcesPropertyResolver provided by Spring Framework Use PropertySourcesPropertyResolver provided by Spring Framework #1273
5bfd01b Update dependencies for grace-boot-mongodb Upgrade to Grace Data MongoDB 2024.0.0-M1 #1120
16de4f5 Update README - Update the versions of Groovy, Gradle, Spring Boot
99b6884 Remove duplicated
grails.factoriesin grace-web-url-mappings Refactor grace-web-url-mappings #1245737b52f Update
migration.gdslin the database-migration plugin Updatemigration.gdslin the database-migration plugin #1240migrationDirtodb/migrationscolumnmethods definded increateTableaddColumncreateIndexinsertloadDataloadUpdateDataupdate9226c41 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
04ae29f Merge hibernate plugin into the framework Merge Hibernate plugin into the framework #1229
5abdc5e Update the BOM of Grace Dependencies Update the BOM of Grace Dependencies #1220
d2638e2 Update Gradle Version Catalog after importing 'cache' 'fields' 'scaffolding' 'views' plugins Update Gradle Version Catalog after importing 'cache' 'fields' 'scaffolding' 'views' plugins #1219
05980f8 Rename the package of Grace Views Rename the package of Grace Views #1218
grails.plugin.json.view=>org.grails.views.jsongrails.plugin.markup.view=>org.grails.views.markup1070acb Refactor Grace Json View API: Use native
groovy.json.*API instead Refactor Grace Json View API: Use nativegroovy.json.*API instead #1217grails.plugin.json.builder.StreamingJsonBuildergrails.plugin.json.builder.JsonOutputgrails.plugin.json.builder.JsonGeneratorgrails.plugin.json.builder.DefaultJsonGeneratorgrails.plugin.json.view.api.JsonWritablegrails.plugin.json.util.JsonToken6f352e4 Refactor Grace Views Format Java and Groovy source and test code Refactor Grace Views #1216
1095028 Merge grace-views into the framework Merge grace-views into the framework #1215
63de64a Refactor Grace Fields Plugin Refactor Grace Fields Plugin #1214
ef9944c Refactor Grace Scaffolding Core and Plugin Refactor Grace Scaffolding Core and Plugin #1213
bdecfc0 Make grace-plugin-fields and grace-plugin-scaffolding works Merge grace-fields into the framework #1211 Merge grace-scaffolding into the framework #1212
grails-plugin.xmlfor grace-plugin-fields and grace-plugin-scaffolding@TagLibtoFormFieldsTagLibContextMarkupRendererContextMarkupRendererImplDomainMarkupRendererImplDelegatingBeanPropertyAccessorImplDomainMarkupRendererSpecandFormFieldsTemplateServiceSpece0ace00 Refactor Grace Cache Core and Plugin Refactor Grace Cache Core and Plugin #1210
566f3d2 Make grace-cache-core and grace-plugin-cache works Merge grace-cache into the framework #1209
@TagLibtograils-plugin.xml2aa5367 Enhance
CodeGenConfigEnhanceCodeGenConfig#1201loadDefaultConfig()to simplify usagee0f2608 Relocate
CodeGenConfigfrom grace-api to grace-bootstrap RelocateCodeGenConfigfrom grace-api to the grace-bootstrap #1200e166042 Rename beans to
propertySourcesPlaceholderConfigurerbeanPropertyOverrideConfigurerto keep naming consistent with theCoreConfigurationBeansgrailsPlaceholderConfigurerandmapBasedSmartPropertyOverrideConfigurerdefined in GrailsApplicationBuilder are inconsistent with theCoreConfiguration#1198cf01cbf Refine GroovyPagesTemplateRenderer
grace-web-gspfromgrace-plugin-domain-class60e7962 Move
CamelCaseUrlConverterSpecandHyphenatedUrlConverterSpecfrom grace-core to the grace-web-common Refactor Controllers and UrlMappings plugins #1189f39e5cf BuildSettings.APP_BASE_DIR: rename
base.dirtograils.base.dirBuildSettings.APP_BASE_DIR: renamebase.dirtograils.base.dir#1186e7e1257 Improve
EntityTraitInjectorandGormTransformerImproveEntityTraitInjectorandGormTransformer#1184EntityTraitInjectorandGormTransformer17e7afe Remove the configuration of system properties in
GrailsGradlePlugin.configureGrailsBuildSettings()Remove the configuration of system properties inGrailsGradlePlugin.configureGrailsBuildSettings()#1173 Allow developers to customize theappdirectory #11577ff8e8b Update
GspCompileOptions: remove the use of deprecatedAbstractOptionsUpdateGspCompileOptions: remove the use of deprecatedAbstractOptions#1166 Support Gradle 9 #1165f7e33da Enhance
FindMainClassTaskandGrailsGradlePlugin.registerFindMainClassTask()EnhanceFindMainClassTaskandGrailsGradlePlugin.registerFindMainClassTask()#1163a7a1a54 Add
configDirtoGroovyPageForkCompileTaskAnd migrateproject.buildDirtoproject.layout.buildDirectoryAddconfigDirtoGroovyPageForkCompileTask#1162c284a33 Task
compileWebappGroovyPagesshould dependsOnclassesTaskcompileWebappGroovyPagesshould dependsOnclasses#11617b7d827 Update Gradle Version Catalog Update Gradle Version Catalog #1145
99554ca Rename
grace-gormtograce-dataproperties in the Grace BOM Renamegrace-gormtograce-dataproperties in the Grace BOM #1144c9ff2fc Improve GroovyCompiler to allow Groovy scripts to be recompiled and reloaded after modification 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 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 Update .gitattributes to ensure the web fonts are treated as binary #1138
452b092 Migrate to Central Portal OSSRH Staging API Migrate to Central Portal OSSRH Staging API #1114
🎯 Refactoring
#1295 Restore grace-web-databinding module c714723
DataBinder.DEFAULT_DATE_FORMAT#1260 Create grace-web-rest module
RendererRegistryCustomizerallow to customizeRendererRegistry, likeDefaultRendererRegistryCustomizer, to add more user-definedRenderer#1254 Refactor GrailsExceptionResolver 1622cf5
GrailsUrlMappingsExceptionResolverto make grace-web-mvc decoupled from grace-web-url-mappingsGrailsExceptionResolvershould not reuse cached controller attribute to find the given error pathGrailsWrappedRuntimeException#1253 Refactor grace-web-url-mappings c843dd9
setGrailsCorsConfiguration()inUrlMappingsHandlerMapping, useAbstractHandlerMapping.setCorsConfigurations()insteadUrlMappingsErrorPageCustomizerandAnsiConsoleUrlMappingsRendererSpecto grace-plugin-url-mappingssetGrailsCorsConfiguration()inUrlMappingsHandlerMapping, useAbstractHandlerMapping.setCorsConfigurations()instead#1252 Various improvements related to stack trace logging and exception display 98e54e7
grailsResourceLocatorfirstgrailsResourceLocatorneed to setsearchLocationtoBuildSettings.BASE_DIRgrails.full.stacktracegrails.full.stacktracegrailsResourceLocatorfirst AndgrailsResourceLocatorneed to setsearchLocationtoBuildSettings.BASE_DIR#1250 Create grace-plugin-taglibs 5057f8f
org/grails/plugins/web/taglib/*TagLibfrom grace-plugin-gsp to grace-plugin-taglibs Create grace-plugin-taglibs #1249#1248 Consolidate 'grace-web-sitemesh' into 'grace-web-gsp' 7457d09
#1247 Make 'grace-web-mvc' decoupled from 'grace-web-sitemesh' efc9af4
#1246 Consolidate 'grace-web-common' into 'grace-web' 3fdd3e0
#1245 Relocate
AnsiConsoleUrlMappingsRendererUrlMappingsReportCommandfrom grace-web-url-mappings to grace-plugin-url-mappings 760c80fAnsiConsoleUrlMappingsRendererUrlMappingsReportCommandfrom grace-web-url-mappings to grace-plugin-url-mappings#1244 Consolidate 'grace-web-databinding' into 'grace-web-common' a8f066d
DataBinderWebDataBindingWebDataBindingTraitInjectorfrom 'grace-web-databinding' to 'grace-plugin-databinding'org/grails/web/databinding/*from 'grace-web-databinding' to 'grace-web-common'#1243 Consolidate 'grace-web-jsp' into 'grace-web-gsp' 9663510
#1242 Cleanup dependencies 4143506
Relocate
ErrorsViewStackTracePrinterGrailsWrappedRuntimeExceptionfromgrace-web-commontograce-web-mvcRemove
getPagesTemplateEngine()ofGrailsApplicationAttributesUpdate 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
grace-web-gsp-taglibmodule its functionality has been consolidated intograce-web-taglibandgrace-plugin-gsporg/grails/plugins/web/taglib/*fromgrace-web-gsp-taglibtograce-plugin-gspStandaloneTagLibraryLookupfromgrace-web-gsp-taglibtograce-web-taglib#1205 Refactor GrailsApplicationLifeCycle 29476e5
GrailsApplicationPostProcessor.setGrailsApplicationLifeCycle()toGrailsApplicationPostProcessor.setGrailsApplicationLifecycle()#1204 Refactor Grace Spring Boot and Grace Spring e3af96e
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.configpackage from grace-core and grace-spring-boot to grace-bootstrapMove
NavigableMapNavigableMapConfigfrom grace-api to grace-bootstrapMove
ConfigPropertiesConfigPropertiesSpecfrom grace-plugin-core to grace-bootstrapRename
GroovyConfigPropertySourceLoaderYamlPropertySourceLoaderpackage fromorg.grails.spring.boot.envtoorg.grails.config.loaderef0eab9 Move
ConfigPropertiesConfigPropertiesSpecfrom grace-plugin-core to grace-bootstrapd888ad8
NavigableMapNavigableMapConfigfrom grace-api to grace-bootstrapConfigMapSpecNavigableMapSpecfrom grace-api to grace-bootstrap204c4eb
GroovyConfigPropertySourceLoaderYamlPropertySourceLoaderpackage fromorg.grails.spring.boot.envtoorg.grails.config.loaderGroovyConfigPropertySourceLoaderSpecYamlPropertySourceLoaderSpecgrace-plugin-core/src/main/resources/META-INF/spring.factoriesb43df23
org.grails.configpackage from grace-core and grace-spring-boot to grace-bootstrapCompositeConfigEnvironmentAwarePropertySourceNavigableMapPropertySourcePrefixedConfigPrefixedMapPropertySourcePropertySourcesConfigfrom grace-core to grace-bootstrapNavigableMapNestedEqualitySpecNavigableMapPropertySourceSpecNavigableMapSpringProfilesSpecPropertyResolutionSpecPropertySourceConfigSpecPropertySourcesConfigSpecSystemEnvironmentConfigSpecfrom grace-core to grace-bootstrapGroovyConfigPropertySourceLoaderYamlPropertySourceLoaderfrom grace-spring-boot to grace-bootstrapGroovyConfigPropertySourceLoaderSpecYamlPropertySourceLoaderSpecfrom grace-spring-boot to grace-bootstrap#1202 Relocate
NamedandDescribedfrom 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()instead0b1c423 Remove deprecated constants in GrailsApplication
#1197 Revisit Grace Spring Boot Module 3976243
Move some classes to more appropriate modules
GroovyConfigPropertySourceLoaderSpecYamlPropertySourceLoaderSpectograce-spring-boot/src/test/groovy/org/grails/spring/boot/env/ClassEditorPropertiesEditortograce-spring-boot/src/main/groovy/org/grails/spring/beans/support/ClassRelativeClassLoaderClassRelativeResourcePatternResolverfrom grace-spring-boot to grace-plugin-i18nGrailsPlaceholderConfigurerGrailsBeanPropertyOverrideConfigurerfrom grace-spring-boot to grace-plugin-coreNavigableMapPropertySourceNavigableMapPropertySourceSpecfrom grace-api to grace-spring-boot#1196 Refactor IOUtils 1711f51
#1195 Migrate to Spring Framework's Resource API 1d34cd4
d18a2b9 Use
PathMatchingResourcePatternResolverinstead ofCachingPathMatchingResourcePatternResolver50cce34 Move
ResourceLocatorfrom grace-api to the grace-coreDefaultResourceLocatorfrom grace-plugin-api to the grace-coreorg.grails.coreio.PluginPathAwareFileSystemResourceLoader2a67789 Use
StaticResourceLoaderin the grace-bootstrapbfec5ab Use built-in classes such as Resource ResourceLoader provided by the Spring framework
The following classes have been removed
#1194 Refactor Grace API f09d429
ff0729e Move
MixinMixinTargetAwarefrom grace-api to grace-coreMove
CacheEntryPairTriplefrom grace-api to grace-utilMove
AbstractTypeConvertingMapTypeConvertingMapTypeConvertingMapTestsfrom grace-api to grace-util813adaf
CompositeConfigEnvironmentAwarePropertySourcePrefixedConfigPrefixedMapPropertySourcePropertySourcesConfigfrom grace-api to the grace-coreNavigableMapPropertySourceSpecfrom grace-core to grace-apiDefaultGrailsPluginTestsfrom grace-plugin-api to grace-test-suite-uber13a0a0d
DefaultErrorsPrinterfrom grace-api to the grace-coreNewInstanceCreationExceptiontoGrailsClassCreationExceptionand relocate to grace-coreGrailsDomainExceptiontoGrailsClassExceptionand relocate to grace-coreInvalidPropertyExceptiontoGrailsPropertyInvalidExceptionand relocate to grace-core08e06a4
AbstractGrailsClassAbstractInjectableGrailsClassfrom grace-api to the grace-coreInvalidVersionExceptionVersionComparatorGrailsPluginPluginSourcefrom grace-api to the grace-plugin-apiaeb674b Move
ConfigPropertiesfrom grace-api to the grace-plugin-core784c2d3 Move
GrailsFactoriesLoaderfrom grace-api to the grace-bootstrap42b116b Move
Settingsfrom grace-api to the grace-bootstrap#1193 Refactor GSP plugin 6a440fc
GrailsTagLibClassDefaultGrailsTagLibClassTagLibArtefactHandlerControllerTagLibraryTraitInjectorinherit directly fromTraitInjectorAdapterArtefactTypes.TAG_LIBRARYinstead ofTagLibArtefactHandler.TYPE#1192 Refactor Bootstrap Artefact 0ae405b
30ababb Relocate
BootstrapArtefactHandlerBootstrapArtefactHandlerSpecto grace-bootGrailsBootstrapClassDefaultGrailsBootstrapClassfrom grace-web to grace-bootGrailsApplicationBuilder2c585fe Auto-configure
BootstrapClassRunnerBootstrapClassRunnerfrom grace-plugin-controllers to grace-bootBootstrapClassRunnertoGrailsBootstrapClassRunnerGrailsBootstrapClassRunnerin GrailsBootstrapAutoConfigurationgrails.bootstrap.skipto Spring Configuration Metadata7d7a392 Use
ArtefactTypes.BOOTSTRAPinstead ofBootstrapArtefactHandler.TYPE#1191 Refactor Grace Boot 86e998f
ApplicationArtefactHandlerApplicationClassInjectorfrom grace-core to grace-bootLoggingTransformerSpecfrom grace-logging to grace-bootArtefactTypeAstTransformationSpecGlobalGrailsClassInjectorTransformationSpecGrailsAwareInjectionOperationSpec#1190 Refactor Services plugin 907ece2
ArtefactTypes.SERVICEinstead ofServiceArtefactHandler.TYPEGrailsServiceClassDefaultGrailsServiceClassfrom grace-core to grace-plugin-servicesServiceArtefactHandlerServiceArtefactHandlerSpecto grace-plugin-servicesServiceUnitTest#1189 Refactor Controllers and Controllers plugins ba72157
50ba03c Move
DefaultGrailsControllerClassSpecto the grace-plugin-controllersd053ffb Refactor UrlMappings plugin
ArtefactTypes.URL_MAPPINGSinstead ofUrlMappingsArtefactHandler.TYPEGrailsUrlMappingsClassDefaultGrailsUrlMappingsClassfrom grace-core to grace-web-commonUrlMappingsArtefactHandlerUrlMappingsArtefactHandlerSpecto grace-plugin-url-mappingscb14e53 Refactor Controllers plugin
ArtefactTypes.CONTROLLERinstead ofControllerArtefactHandler.TYPEActionCamelCaseUrlConverterHyphenatedUrlConverterUrlConverterfrom grace-core to grace-web-commonControllerArtefactHandlerControllerArtefactHandlerSpecto grace-plugin-controllersLoggingTransformerSpecin grace-loggingControllerLoggingTransformerSpecto grace-plugin-controllers#1188 Refactor Domain Class plugin eb281db
DomainClassArtefactHandlerto grace-plugin-domain-classDefaultGrailsApplication.addArtefact()fromDomainClassArtefactHandlerArtefactTypes.DOMAIN_CLASSinstead ofDomainClassArtefactHandler.TYPEGrailsASTUtils.isDomainClass()instead ofDomainClassArtefactHandler.isDomainClass()#1187 Refactor Domain Class plugin 8fb1916
AnnotationDomainClassArtefactHandlerDefaultGrailsDomainClassInjectorto grace-plugin-domain-class#1185 Refactor Domain Class plugin ac7f0ac
grace-corefromgrace-plugin-domain-classgrace-coreintograce-plugin-domain-class#1183 Merge async and events plugins into the framework 8d780cc
#1182 Restructure GORM Support 8853c8c
grace-datastore-gorm-supportSee Decouplegrace-datastore-gorm-supportfrom Grace framework grace-data#73EntityTraitInjectorandGormTransformerfromgrace-datastore-gorm-supportSee Decouplegrace-datastore-gorm-supportfrom Grace framework grace-data#73#1180 Refactor Gradle Doc Plugin 3f68dc3
50977dc Refactor DocPublisher
publishPdf()togeneratePdfGuide()PublishPdfTask4b19463 Refactor GrailsDocGradlePlugin
docstopublishGuidesinglePdfgeneratePdftoPublishGuideTaskdocsPdf#1176 Refactor Gradle Doc Plugin a7386c2
#1175 Refactor Grace Banner 8b4f907
205a718 Refactor GrailsResourceBanner
ResourceBannerMetadata.getApplicationName()efe2899 Refactor GrailsResourceBanner
getApplicationVersion(Class<?> sourceClass)#1174 Refactor Gradle plugins 3c7f267
edc3a51 Refactor GrailsGradlePlugin
enableNative2Ascii()in favor of using Gradle'sProcessResourcesnative2asciiandnative2asciiAntinGrailsExtensionb4a4643 Refine GrailsPluginGradlePlugin
ProcessPluginResourcesTaskconfigurePluginResources()dc80af8 Refine GrailsGradlePlugin and GrailsWebGradlePlugin
configureProcessResources()forGrailsWebGradlePluginGrailsGradlePlugin.enableNative2Ascii()toGrailsWebGradlePlugin#1172 Refactor Gradle Profile Plugin 8008127
8f89eb1 Refactor GrailsProfileGradlePlugin
PROCESS_PROFILE_RESOURCES_TASK_NAMECOMPILE_PROFILE_TASK_NAMEPROFILE_GROUPregisterOrGetJarTask()andregisterOrGetSourcesJarTask()sourcesJarTask4a39330 Refactor GrailsProfileGradlePlugin
ProfileResourcesProcessTaskProfileCompilerTaskGrailsProfileGradlePlugin#1171 Support configuration of project resources and sources directories 5821a9c
#1170 Customize Groovy compiler configuration 4a64a9e
configScript.metaDataMap,config/groovy/compiler.groov,#1169 Refactor Gradle plugins eb884d5
7d686e4 Refactor GrailsGradlePlugin
GenerateBuildInfo@CompileDynamiconcreateBuildPropertiesTask()4aba8f5 Refactor GrailsGradlePlugin
GenerateConfigScriptconfigureGroovyASTMetadata()toconfigureGroovyCompiler()#1168 Refactor Gradle plugins 3b4ba01
#1167 Refactor Gradle plugins e844d7e
76633b6 Improve GroovyPagePlugin and GroovyPageForkCompileTask
jakarta.servlet-apiprovidedCompile, only usecompileClasspathTask.getProject()from a task actionJavaPlugin.CLASSES_TASK_NAMEinstead ofclassesGrailsGradlePlugin.GRAILS_EXTENSION_NAMEdbe50eb Refactor GrailsProfileGradlePlugin
BasePlugin.ASSEMBLE_TASK_NAMEinstead ofassembleCONFIGURATION_NAMEtoGRAILS_CONFIGURATION_NAMERUNTIME_CONFIGURATIONtoPROFILE_CONFIGURATION_NAMEproject.configurationsandproject.extensions9cdf38f Update ApplicationContextCommandTask and ApplicationContextScriptTask
dependsOnof the tasksApplicationContextCommandTaskandApplicationContextScriptTaskdependsOnwhen registering the tasks5011c46 Refactor
GrailsGradlePluginJavaPlugin.CLASSES_TASK_NAMEinstead ofclassesproject.configurationsandproject.extensionsGRAILS_EXTENSION_NAMEFIND_MAIN_CLASS_TASK_NAMEBUILD_PROPERTIES_TASK_NAMECONSOLE_CONFIGURATIONtoCONSOLE_CONFIGURATION_NAMEPROFILE_CONFIGURATIONtoPROFILE_CONFIGURATION_NAMEaddDefaultProfile()#1164 Refactor Gradle Plugins cd3486d
383a6be Improve
GrailsPluginGradlePlugintasks.register()instead oftasks.create()d5de8f5 Configure the main application class name fo
runScripttaskbbf1781 refactor
configureGrailsBuildSettings()andconfigureSpringBootExtension()configureGrailsBuildSettings()return tovoidproject.buildDirSourceSets85c0691 refactor
configurePathingJarbuildClasspath()project.layout.buildDirectoryinstead ofproject.buildDirresolveClassesDirs()private979f6c6 refactor
enableNative2Ascii()ant.native2ascii()createNative2AsciiTaskff169eb refactor
createBuildPropertiesTask()voidtasks.register()instead oftasks.create()1b8aa4b refactor
configureConsoleTask()createConsoleTask()andcreateShellTasktasks.register()instead oftasks.create()b544809 refactor
configureApplicationCommands()tasks.register()instead oftasks.create()@CompileDynamic1e45f77 refactor
configureRunScript()andconfigureRunCommand()tasks.register()instead oftasks.create()@CompileDynamiceb83712 refactor
configureGroovyASTMetadata()tasks.register()instead oftasks.create()tasks.named()instead oftasks.getByName()@CompileDynamic#1157 Allow developers to customize the
appdirectory 2ee497bGrails 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
appdirectory 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-appas a fixed directory since its inception. In Grace, we can usegrails-app, or the more conciseapp.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, orstore.#1149
Applicationtype artifacts are supported in both theapp/bootandsrc/maindirectories 5b594a8Applicationtype artifacts are supported in both theapp/bootandsrc/maindirectoriesapp/inittoapp/boot#1148 Move artefact
Bootstrap.groovyfromapp\inittoapp\boot09ab913#1147 Rename artefact type
BootStraptoBootstrape1b61a4BootStrap.groovytoBootstrap.groovyDefaultGrailsBootstrapClass.BOOT_STRAPtoBootstrapas the trailing part of the Bootstrap class typeBootStrapClassRunnertoBootstrapClassRunnerbootstrapClassRunnerinControllersGrailsPluginbaseprofile#1140 Refactor GroovyCompiler ae3ef71
GroovyCompilerfor better compilation of Groovy scripts ImproveGroovyCompilerfor better compilation of Groovy scripts #1139Only use Groovy Grape's runtime dependencies to load
ArtefactHandlerClassInjectorTraitInjector, so the Shell no longer needgrace-plugin-controllersgrace-plugin-gspgrace-plugin-url-mappings, which greatly reduces the size of the final CLI installation package.#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
isDomainClass()in DomainClassArtefactHandler@TagLibfor TagLibArtefactHandler@TagLibraryas artefact type, use@TagLibinstead@Artefact()annotation to Grails artefacts in the testsClassInjector
ClassInjector.shouldInject(URL), in favor ofshouldInject(ClassNode)TraitInjector
boolean supports(ClassNode)to check if the classNode need to be injectedGrailsASTUtils
getGrailsArtefactType()to GrailsASTUtilsisDomainClass()in GrailsASTUtilsGrailsGradlePlugin: configure Groovy AST Metadata for configurationScript of GroovyCompileOptions
GlobalGrailsClassInjectorTransformation and GlobalGrailsPluginTransformation
Grails with Spring Boot DevTools
RunCommand
🚀 Dependency Upgrades
⚙️ Tasks
🍀 Grace Projects
📜 Grace Profiles
Full Changelog: v2024.0.0-M1...v2024.0.0-M2
This discussion was created from the release v2024.0.0-M2.
Beta Was this translation helpful? Give feedback.
All reactions