mercredi 27 mai 2015

Ruby on Rails two completely different databases on the same project

I spent last couple of hours searching the web for this solution and I didn't find any, so I wanted to ask here if anyone has experience with something like this.

I started working on a very big Rails project and I've got some very strange request from the project manager.

He wants me to use 2 different MySQL databases for different environments (which I already found how to do here

Apart from this he wants to make a small local database which would serve as an autosave vault for the recent documents (maybe 5-10 recent documents) and he wants this database to be a SQLite.

Since I just started with the Rails recently I didn't even know if this sort of connection is possible, and is something like this even possible in Rails.

I also thought of using a Connection Pool to ensure thread safety.

Any advice and help is appreciated.

Aucun commentaire:

Enregistrer un commentaire