Grails Changelog

What's new in Grails 4.0.1

Nov 8, 2019
  • Grails 4 ships with the following dependency upgrades:
  • Groovy 2.5.6
  • GORM 7 and Hibernate 5.4 (now the default version of Hibernate for new applications)
  • Spring Framework 5.1.5
  • Spring Boot 2.1.3
  • Gradle 5.1.1
  • Spock 1.2
  • Micronaut Parent Context:
  • Micronaut is now the parent application context of Grails thus allowing using many Micronaut features including the Micronaut HTTP Client and Kafka Client.
  • Micronaut has also been used to improve startup and reduce overall memory consumption of Grails applications (along with associated improvements in Spring Boot 2.1).

New in Grails 3.0.4 (Jul 29, 2015)

  • This release restores dynamic scaffolding as a feature. To use it requires the 3.1.0 version of the scaffolding plugin to be in compile scope in build.gradle:
  • compile "org.grails.plugins:scaffolding:3.1.0"

New in Grails 3.0.0 (Mar 31, 2015)

  • Core Features:
  • Groovy 2.4:
  • Grails 3.0 comes with Groovy 2.4 which includes many new features and enhancements.
  • Spring 4.1 and Spring Boot 1.2:
  • Grails 3.0 comes with Spring 4.1 which includes many new features and enhancements.
  • In addition, Grails 3.0 is built on Spring Boot 1.2 which provides the ability to produce runnable JAR files that can embed Tomcat, Jetty or Undertow containers.
  • Gradle Build System:
  • Grails 3.0 deprecates the older Gant-based build system in favour of a new Gradle-based build that integrates closely with the Gradle plugin ecosystem.
  • Application Profiles:
  • Grails 3.0 supports the notion of application profiles via a new profile repository. A profile encapsulates an application structure, set of commands, plugins and capabilities. For example the "web" profile allows construction of web applications deployable to a Servlet container. In the future more profiles will be developed targeting different environments.
  • Redesigned API based on Traits:
  • The Grails API has been redesigned so that public API is correctly populated under the grails. package whilst private / internal API that is subject to change can be found in the org.grails. package. The core API has also been rewritten and based around the Groovy Traits.
  • Web Features:
  • New Interceptors API:
  • In previous versions of Grails, filters were used to define logic that intercepts controller action execution.
  • As of Grails 3.0, this API is deprecated and has been replaced by the new Interceptor API. An example interceptor can be seen below:
  • class MyInterceptor {
  • boolean before() { true }
  • boolean after() { true }
  • void afterView() {
  • // no-op
  • Development Environment Features:
  • New Shell and Code Generation API:
  • Replacing Gant, Grails 3.0 features a new interactive command line shell that integrates closely with Gradle and provides APIs for writing scripts that interact with Gradle and perform code generation.
  • The new shell integrates closely with the concept of application profiles with each profile capable defining profile specific commands. As with previous versions of Grails, plugins can define new shell commands that can invoke Gradle or perform code generation and project automation tasks.
  • Enhanced IDE Integration:
  • Since Grails 3.0 is built on Gradle, you can now import a Grails project using IntelliJ community edition or GGTS's Gradle tooling support without the need for Grails specific tooling. Grails 3.0 plugins are published as simple JAR files greatly reducing the need for additional IDE support specific to Grails.
  • Application Main Class:
  • Each new Grails 3.0 project features an Application class that has a traditional static void main signature, meaning to run or debug a Grails 3.0 application from an IDE like IntelliJ or GGTS you can simply right-click on the Application class and execute to start your Grails application. All Grails 3.0 tests can also just be run from the IDE directly without needing to resort to the command line (even integration / functional tests!).
  • Testing Features:
  • Integration and Geb Functional Tests:
  • Grails 3.0 supports built in support for Spock/Geb functional tests using the create-functional-test command. Functional tests are based on Spring Boot's test running mechanism and load the application just once for an entire suite of tests. The tests can be run from and IDE and don't require the command line.
  • Gradle Test Running:
  • Since Grails 3.0 is built on Gradle the test execution configuration is much more flexible and can easily configured to execute in parallel.

New in Grails 3.0.0 Milestone 1 (Jan 29, 2015)

  • Using LESS:
  • LESS is great when you want to compile your bootstrap code from source or just to use in place of css in general.
  • At the moment, in order to use less you must define both a buildscript dependency as well as a runtime dependency. This allows you to both use the less processor in debug / development mode as well as during war assembly for precompilation.
  • Now you can simply rename your application.css file to application.less and go to town. It is even possible to download Bootstrap 3.2.2 from source and use that in your runtime directly.
  • Coffeescript:
  • You can also take advantage of coffeescript processing by adding the com.bertramlabs.plugins:coffee-asset-pipeline:2.0.6 file to your dependencies as well as your buildscript dependencies.
  • This plugin has some nice features such as being able to take advantage of the node coffeescript binary, if available, for faster processing times.
  • Handlebars:
  • Just like the others, simply add the com.bertramlabs.plugins:handlebars-asset-pipeline:2.1.1 plugin to your project. At first you will have to keep your own copy of handlebars-runtime.js to render the resultant compiled .hbs files. However, in the next AP release for grails, the application will be capable of accessing the included copy of handlebars from its META-INF/assets folder.
  • Build Options:
  • Grails takes advantage of using the already existant gradle plugin for asset-pipeline. This means we can use those config options directly in our build.gradle file to control how these files are compiled for production.

New in Grails 2.3.4 (Dec 6, 2013)

  • Bug:
  • [GRAILS-7833] - Cannot Use Join Table in Non-Default Schema in PostgreSQL
  • [GRAILS-8737] - Grails does not recognize already existent join table in one to many relationship using a postgres schema mapping
  • [GRAILS-9778] - Grails on Cygwin shows "can't convert empty path"
  • [GRAILS-9805] - GORM autoTimestamp not working for sequence-based databases
  • [GRAILS-10207] - Constraints are ignored when a mapping block is defined for a property
  • [GRAILS-10469] - projections in createCriteria return error result
  • [GRAILS-10594] - Create test-app: error in opening zip file
  • [GRAILS-10686] - NoSuchMethodError for GormStaticApi.setTransactionManager()
  • [GRAILS-10692] - Unable to add spring-ldap dependencies to grails project
  • [GRAILS-10714] - NoSuchMethodError for GormStaticApi.setTransactionManager() when running using Maven
  • [GRAILS-10736] - Running with Maven and Oracle the database configuration is ignored and h2 is always used
  • [GRAILS-10793] - On Windows, grails v2.3.2 or 2.3.3 (new project) adding BuildConfig dependencies results in plugin errors. Works on 2.3.1!
  • [GRAILS-10803] - Can't see chinese in log console in 2.3.x
  • [GRAILS-10806] - Custom headers are not send as part of the reply for application/json
  • [GRAILS-10817] - JSON converter charset issue
  • [GRAILS-10818] - It is possible for an old version of a groovy jar to end up in a war file
  • [GRAILS-10820] - Group UrlMappings Producing null Params
  • [GRAILS-10822] - Grails 2.3 compass errors
  • [GRAILS-10823] - Regression in Grails 2.3.3 - JSONWriter encodes slashes.
  • [GRAILS-10824] - Grails 2.3.3 - test-app fails with forked execution (Grailsc cannot be found)
  • [GRAILS-10829] - Elements of a collection association are not being deleted
  • [GRAILS-10831] - DetachedCriteriaTransformer cannot resolve dynamic properties
  • [GRAILS-10835] - Parent Resources in UrlMappings holds incorrect ancestry
  • [GRAILS-10837] - Cannot use Data Binding/ValueConverter for an Enum field
  • [GRAILS-10839] - Raw encoder does not work in layouts
  • [GRAILS-10845] - NoSuchMethodException with abstract controllers and exception handlers
  • [GRAILS-10853] - data binding and many-ended associations
  • [GRAILS-10864] - xml data binding doesnt work
  • [GRAILS-10865] - Wrong generic type binding if filed is in parent class
  • [GRAILS-10866] - Groovy exception handlers in controllers do not compile
  • [GRAILS-10867] - app lib jars are left out of resolve cache
  • [GRAILS-10868] - xml collection binding - can not update existing collection items.
  • [GRAILS-10871] - BindindFormat and constraints block adding two errros on the same field
  • [GRAILS-10876] - JSON.use('deep') Fails on Null Association
  • [GRAILS-10886] - On Windows, grails v2.3.2, 2.3.3, 2.34 (new project) adding BuildConfig dependencies results in plugin errors. Works on 2.3.1!
  • Improvement:
  • [GRAILS-10554] - typeMismatch error for command object shouldn't go with nullable error
  • New Feature:
  • [GRAILS-10838] - Grails 2.3.x equivalent for StructuredPropertyEditor
  • Task:
  • [GRAILS-10840] - Review usages of InputStreamReader and OutputStreamWriter that use the value of "file.encoding" system property
  • [GRAILS-10846] - Upgrade To grails-data-mapping 2.0.5

New in Grails 2.3.3 (Nov 22, 2013)

  • Bug:
  • [GRAILS-6314] - grails.sitemesh.default.layout is applied to render "...some text...."
  • [GRAILS-9056] - render file: shortcut broken in 2.0.3
  • [GRAILS-9504] - Forward isn't working properly when using hyphenated url
  • [GRAILS-10520] - Grails REST HalJsonRenderer fails with eagerly loaded many-many relation ship entities
  • [GRAILS-10572] - `pom true` with Aether ignores exclusions in project POM
  • [GRAILS-10636] - grails run server on develop mode render controller action result as JSON, 404 error after controller modified
  • [GRAILS-10653] - _GrailsWrapper assumes grailsHome is set - not case for Maven/Gradle
  • [GRAILS-10720] - Cannot create mock for class
  • [GRAILS-10735] - Error in reloading domain class changes
  • [GRAILS-10748] - @PostConstruct annotation broken in service with @Transactional annotation. "method annotation requires a no-arg method"
  • [GRAILS-10749] - DataBindingListeners in the application context are invoked even if their supports() method returns false
  • [GRAILS-10756] - Can't start any app in forked mode
  • [GRAILS-10760] - Typo in Description section of Params
  • [GRAILS-10763] - UrlMappings doesn't support comments on web.xml generation
  • [GRAILS-10765] - npe on org.codehaus.groovy.grails.web.util.StreamCharBuffer.toCharArray
  • [GRAILS-10766] - False positives for unique constraints after upgrading to 2.3.2
  • [GRAILS-10768] - console: setTargetDirectory() throws exception after creating first domain model
  • [GRAILS-10770] - "IllegalArgumentException: Cannot disposition [head] to this request" after upgrading to Grails 2.3.x
  • [GRAILS-10775] - Environment.developmentMode doesn't work because of cache error
  • [GRAILS-10776] - Files within src/groovy of added plugins cannot be found on very first test-app
  • [GRAILS-10777] - printlns are no longer part of test report
  • [GRAILS-10778] - Databinding maps documentation doesn't work
  • [GRAILS-10780] - Can't render text in an afterView filter
  • [GRAILS-10781] - HAL JSON rendering contains quotes for Enum
  • [GRAILS-10783] - Nested/merged g:applyLayout is broken with grails.views.gsp.sitemesh.preprocess=false setting
  • [GRAILS-10785] - JUnit3 Integration Test Case: data created within setup method is not rollbacked at the end
  • [GRAILS-10796] - Collection associations assigned via properties are added rather than replaced
  • [GRAILS-10808] - Add relativeUri attribute for link, createLink, form, etc. tags
  • Improvement:
  • [GRAILS-9941] - The manual 2.12 and 2.13 are confusing
  • [GRAILS-10410] - Make it possible to pass model to layout template in g:applyLayout
  • [GRAILS-10761] - Add @NotTransactional annotation for marking a method to be skipped from class level @Transactional annotation transform
  • [GRAILS-10772] - Improve BeforeValidateHelper performance
  • [GRAILS-10789] - Documentation doesn't mention i18n convention for domain fields' labels
  • [GRAILS-10790] - Support same data binding capabilities for collections and maps on groovy classes
  • [GRAILS-10799] - Improve "render obj as JSON" performance
  • Task:
  • [GRAILS-10795] - TODO: update tomcat plugin to 7.0.47 version in default BuildConfig.groovy before next release of Grails