Off the top of my head a couple of ideas come to mind. A quick and dirty way would be to have a separate Django project that only handles the admin app. Another way would be to make a custom model manager that would select the database to use. This way is a little more involved but not impossible.
On Sun, Aug 16, 2009 at 4:44 AM, Haes <haes...@gmail.com> wrote: > > Hi, > > we are using master / slave database replication, no partitioning, > just replicating the complete database to several slaves for > performance reasons. This is making some problems with a newly > developed Django project, which makes use of an existing database. > > Is there an (easy) way to use a different database for the admin > application (master db) than for the remaining apps (slave db)? > > If I'd need more fine grained control about what database connection > I'd like to use in a view, would I need to write a custom db backend > for that? Or is there a way to set up two database connections and > switch them manually (django.db.connection = <slave>)? > > Thanks for any hints. > > Cheers. > > > > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---