Using the classic author/book pattern (grails 2.2.0).
class Author { static hasMany = [books: Book] } class Book { static belongsTo = [author: Author] } Why when I create a child instance it dosent update the parent set:
Author author = new Author().save() Book book = new Book(author: author).save() assert author.books.size == 1 // FAIL As the author object wont change in the database, why do I have to use author.addToBooks(book).save() ???