SQLOS Storage
Category: Database integration & external storage
—
Other products by this author
Current release
No stable release available yet.
If you are interested in getting the source code of this project, you can get it from the code repository.
Experimental releases
There are no experimental releases available at the moment.
Project Description
- Project resources
SQLOS was made for SIP http://sampleinventory.sf.net/ project and uses Zope3 components and SQLObject to store data on diferent RDBMS suported by SQLObject.
To use SQLOS with Zope2.8, Five1.2 and Archetypes today, a special svn branch is needed:
svn co http://codespeak.net/svn/z3/sqlos/branch/jinty-sqlobject0.7-Five sqlos
Example
On the example folder I put a simple ATPerson Type that uses the example package distributed with SQLOS(sqlos_sample), to store Person data on the database.
Dependencies
- Zope2.8.4 (http://www.zope.org)
- Five1.2 (http://codespeak.net/z3/five/)
- SQLOS for Five branch (http://codespeak.net/svn/z3/sqlos/branch/jinty-sqlobject0.7-Five)
- SQLObject-0.7 (http://www.sqlobject.org/)
- FormEncode (http://formencode.org/)
- Archetypes (http://plone.org/products/archetypes)
- Zope3 DA to be used (pyscopgda http://www.zope.org/Products/Zope3-Packages/psycopgda, mysqlda http://www.zope.org/Products/Zope3-Packages/mysqldbda)
Install
You need only to put the SQLOSStorage folder on $INSTANCE_HOME/Products or you PYTHONPATH and import SQLOSStorage class. See examples/person.py
Usage
To adapt you own types to use SQLOSStorage you will need to create a registry a factory class based on SQLOS package. The person.py on the example folder, uses the sqlos_sample.Person class defined on the SQLOS example package. I only add one new field to store the UID of the AT object. To make this I insert this new column definition on the Person class:
uid = StringCol(alternateID=True)
Todo
- Create table using Factory.createTable() method when table does not exist.
- Make SQLOSStorage compatible with portal_factory.
- Store Images and Files on the database.
Author
Rudá Porto Filgueiras <rudazz@gmail.com> [ruda_porto]