GORM for MongoDB – Impressive

SpringSource announces today Grails Object Relational Mapping for MongoDB!


For the people unfamiliar with MongoDB, it is a document oriented database that bridges the gap between key-value stores (which are fast and highly scalable) and traditional RDBMS systems (which provide rich queries and deep functionality).

We’ve been using MongoDB for a while already and have had a few discussions going around whether that’s the right choice, since we use Grails and develop in Groovy, and it appeared that the MongoDB Grails plug-in was immature and not recommended for production, on the other hand we could create the classes Grails domain classes and use [annotate] morphia to map Java/Groovy objects to/from MongoDB, but that would mean more work in the last stages of the sprint, which would put the sprint under a risk.

So, it appears that SpringSource have hidden microphones in our office, and the day we were discussing this issue, they came up with this nice news. [ In fairness to one of our colleagues, I need to tell that he suggested to wait for an update from SpringSource, which actually we are discussing right now ]

Anyways, let’s see what GORM for MongoDB offers:

  • Full support for CRUD operations
    user.save(), user.delete()…
  • Dynamic finders
  • Complex Criteria queries
    def result = User.withCriteria{
    like('name', 'F%')
    'age', 18)
  • Reusable Named Queries

Although many2many relationships are missing, it is great great step forward, and I am sure people using Grails together with MongoDB will appreciate a lot! Well done Guys.

All we need to do now, is to

  1. remove the grails hibernate plug-in (if installed)
  2. create the classes in the Grails domain class folder

Check the manual ( http://grails.github.com/inconsequential/mongo/manual/index.html ) for more information on the new arrival! And share comments with us if you use MongoDB with Grails!

This entry was posted in NoSQL, dynamic languages and tagged , , , , . Bookmark the permalink.

9 Responses to GORM for MongoDB – Impressive

  1. Pingback: Narek Alaverdyan

  2. Pingback: baselogic

  3. Pingback: Enterprise Java

  4. Pingback: baselogic

  5. Pingback: Enterprise Java

  6. Pingback: baselogic

  7. Pingback: Tweets that mention GORM for MongoDB – Impressive | ReadMe -- Topsy.com

  8. Pingback: Enterprise Java

  9. Pingback: Grails/GORM for MongoDB

Leave a Reply

Your email address will not be published. Required fields are marked *


You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>