Is it easy to switch from relational to non-relational databases using Rails?

Good afternoon,

I used Rails / Mysql for the past, but I heard about Cassandra, MongoDB, CouchDB and other DB / Non-relational databases. I plan to study them later, as they can be a better alternative to scalability.

I plan to start the application soon. Will it be different from the Rails design if I move from a relational to a non-relational database? I know that Rails migration is not database dependent, but I was not sure that moving to non-relational would matter with design or not.

+4
source share
2 answers

MongoMapper is mature enough to use it in production (me, for example). You can also use both ActiveRecord and MongoMapper models (I do this too).

It’s very easy to set up associations between them, as described here: http://groups.google.com/group/mongomapper/browse_thread/thread/35d4acabf37e3984#

There is a rails3 branch of MongoMapper using ActiveModel. In the end, this will be part of the chest, but for now you will need to use this rails3 branch if you want to work with rails 3 from get-go github.com/mharris717/mongomapper

0
source

I think MongoDB / MongoMapper is already mature enough and you won't notice the difference. This will be doubly true if these ORMs without relational databases switch to ActiveModel. Thus, they will all have the same basic modules, which will help maintain compatibility between applications.

0
source

Source: https://habr.com/ru/post/1301280/


All Articles