Reputation: 1298
How to use Django with abstract non ORM backend? What to extended and override in models and views files? Unfortunately all examples on Django still assume ORM use. In my case, I try to make it work against Google BigTable using Python API
Upvotes: 0
Views: 688
Reputation: 1916
In your settings.py, in Databases you can specify the Engine you want to use. In django docs it states:
You can use a database backend that doesn’t ship with Django by setting ENGINE to a fully-qualified path
You would need to create some BigTable-Django backend similar to the official ones in here . See that the main thing would be to use the class BaseDatabaseSchemaEditor and “adapt” it to the Python BigTable API.
This is not trivial; for some simple operations and specific use case that may be feasible to do without engaging into too much developing, otherwise it could get quite tedious and some other functionalities may get “broken”. Here you have a similar Django- with non ORM project using DataStore called Djangae, however it is not officially supported and it is for using with AppEngine as well. Anyway you may be able to get some ideas from there.
Upvotes: 1