Datamapper vs ActiveRecord (discussions of pros and cons)

87 views
Skip to first unread message

George

unread,
Feb 9, 2011, 9:11:37 AM2/9/11
to DataMapper
Starting a new Rails3 site that will access a large amount of
relatively simple data. I love Datamapper and my colleague loves
ActiveRecord. Neither of us have a good understanding of the benefits
of one over the other.
Any of you tempted to illustrate the pros and cons of each please?
I hope the discussion will be useful to others too.
Many thanks,
George

Gary Yngve

unread,
Feb 9, 2011, 2:39:30 PM2/9/11
to datam...@googlegroups.com
First, find yourself a copy of "Patterns of Enterprise Application Architecture" by Martin Fowler and read about those two patterns.

For my use, Pros/Cons of Datamapper over AR:
Pros:
- works well for schema-less nosql
- can have multiple versions of the same model across apps/services that expose different properties
- syntax feels sexier than AR
Cons:
- has fewer users, less Rails plugin support than AR
- maybe buggier / less optimized than AR (I need to experiment with how to write some queries in DM because it's not clever enough to figure out the eager loading, nested queries that are too deep, etc.)

-Gary
Reply all
Reply to author
Forward
0 new messages