Allow testing and dumping legacy database without enabling syncdb
|Reported by:||Owned by:||nobody|
|Component:||Database layer (models, ORM)||Version:||1.6|
|Has patch:||no||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
I've run into an issue with multiple databases that seems like it could be a common enough use case to warrant taking a look at. I have a legacy database that I am using a database router for. I have reading enabled, but I would prefer not to allow syncdb since writing and changing structures are handled by the legacy application.
Still, for basic read operations such as dumpdata,
is checked, as well as when creating test databases. My Django app depends on the working legacy database, thus a test database needs to be created as well.
For now I'm overriding this will a custom setting that is modified at run time to indicate whether
should be allowed, but this is obviously not a good long-term solution.