I would like to use SQLRelay for database connection pooling and query-
based routing with a Rails application that I am just about done with.
It is my first Rails project, and I thought it might be wise to get
some feedback on this before I get too far in coding it.
From what I can tell, I am going to have to write a connection adapter
for ActiveRecord if I want to use SQLRelay (http://
sqlrelay.sourceforge.net/) with Rails. While I think this could be a
cool, fun and rewarding project, one that I will certainly be into
doing, time is of essence here (when isn’t it?).
I was hoping someone on this list could add their two cents. I need
something like SQLRelay because the ops department, used to supporting
weighty, slow PHP apps, is refusing to put this Rails website out on
the Internet without support for DB pooling or at least read + write
databases. I’d like the application to respond quickly too, as that
will certainly play a large factor in whether or not the company
continues with Rails development. I’ve implemented caching as best as
I could, but I do still need to point at different databases, with
masters and slaves.
I am currently using acts_as_readonlyable, with some modifications, to
support a read-only database for my main database server.
Unfortunately, I had to use multiple database servers with this Rails
application (a member of my team wrote a plugin to support this along
the way), so the implementation of acts_as_readonlyable is less than
straight-forward.
Advice is greatly appreciated. Have you written a connection adapter
for ActiveRecord? Or, better yet, have you implemented SQLRelay with
ActiveRecord/Rails?
Thanks!!
Jacqui