Forum: Ruby on Rails Independent SQL connections...race condition?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
James R. (Guest)
on 2006-01-12 17:48
(Received via mailing list)
I would like to be able to manage different db connections per request.
I've
gotten this working by using establish_connection in a before_filter on
all
controllers. My concern is whether or not there could be a race
condition
where two or more overlapping requests might reset the SQL connection.
Is
there any serialization logic which will prevent this? Must I introduce
this
logic manually?



Thanks for any help.



James
This topic is locked and can not be replied to.