On Tue, 2009-02-17 at 03:26 -0800, proteus...@gmail.com wrote: > I've been following the discussion about supporting multiple > databases within one project (primarily on a per-app or per-model > basis) with interest and look forward to the feature getting > solidified and implemented into the trunk one day. That doesn't appear > to be a near term event, however, so I was curious what people are > doing to address database scalability issues on a practical basis > currently.
The most direct write-up I know of is something Barbara Shaurette wrote based on some scribblings I did on this list a while back. See http://www.mechanicalgirl.com/view/multiple-database-connection-a-simple-use-case/ > > For example, the Django Auth and Sessions models could absolutely > be deployed onto their own database servers as we do no foreign key > joins to any of those and they have a lot of traffic that I'd like to > not be on my other app db servers. That would be tricky, since the best solution is to add a custom manager, which means modifying built-in models. Modifying the database storage behaviour of third-party models is always going to be tricky, I suspect (even when multi-db support is in Django proper). My gut feeling is that the right view to take on things here is that the third-party stuff (stuff you don't control) should go into the "standard" database and things you do control can have custom managers that direct them to read and/or write somewhere else. I've seen a few implementations of that approach (and whilst I haven't seen what Barbara's done, it sounds like she made it work, too) and they seem to work fairly well. Regards, Malcolm --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---