Saturday, July 6, 2013

Django-Jython: Working With Experimental Database Backends

This is the first of several blogs that I plan to publish regarding the use of experimental database backends with the Django-Jython project. In this series of blogs, I will cover the basics of how to begin using the experimental backends, as well as some details on how to create your own. At the time of this posting, only one "fully supported" backend exists for the Django-Jython project and that is for the PostgreSQL database. However, another experimental backend exists for SQLLite and there are more on the way.In order to build and begin using the experimental backend for SQLLite (or others), you must first obtain a copy of the code, which is available on the , or via your command-line using the following line:svn checkout http://django-jython.googlecode.com/svn/trunk/ django-jython-read-onlyOnce you've obtained the code, it is easy to build. Simply traverse into the root directory of the downloaded code which should be named "django-jython", and perform the build using the setup.py build script as such:jython setup.py buildNow, this works nicely for a build to use the PostgreSQL backend, but it will not include the experimental backend implementations. In order to do so, you must open up the setup.py script and add the experimental backend that you wish to use within the "packages" listing as follows:from distutils.core import setupsetup( name = "django-jython", version = "0.9", packages = ['doj', 'doj.backends', 'doj.backends..zxjdbc', 'doj.backends..zxjdbc.postgresql', 'doj.backends..zxjdbc.sqllite', # Experimental backend 'doj.management', 'doj.management.commands'], ... - Full Post

No comments:

Post a Comment