Canatella
2007-Nov-13 11:35 UTC
multiple database: one vs multiple mongrel + rails processes ?
Hello everybody, I''m creating an application where I would like every customer to have it''s own database, for privacy reason. Each customer will access the application using a wildcard virtual host like customer- name.domain.tld . I''m wondering if I should 1. use multiple instance of mongrel, each running against one database or 2. use one instance of mongrel connecting agains multiple database. At first glance, here are my thought: solution 1., pros: - least intrusive in regards to rails - allows caching of queries solution 1. cons: - need one instance of mongrel + rails per customer, which means lots of memory. - harder maintenance solution 2., pros: - 1 mongrel instance, easier maintenance - smaller memory foot print solution 2. cons: - no caching of sql queries, or I need database connection pooling ? - need to hack in the heart of rails/mongrel_rails What are you thought and advices on this matter ? The access by each customer should be fairly low, maybe 100 hits a day. Thank you very much, -- Damien Merenne http://blog.cosinux.org/ --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---