Skip to main content

A networked standard template library and ORM for python

Project description

A networked standard template library for python.

The data is owned by different, configurable back-end databases and it is accessed using a light-weight Object Relational Mapping (ORM) inspired by Django. The source code is hosted at google code while Documentation and Downloads are available via PyPi.

Backends

Backend databases provide the backbone of the library, while the Object Relational Mapping is the syntactic sugar. Currently the list of back-ends is limited to

Only Redis is fully operational.

Object-relational mapping

The module stdnet.orm is a lightweight ORM. For example:

from stdnet import orm

class Author(orm.StdModel):
    name = orm.AtomField()

class Book(orm.StdModel):
    author = orm.ForeignKey(Author)
    title  = orm.AtomField()

Register models with backend:

orm.register(Author,'redis://localhost/?db=1')
orm.register(Book,'redis://localhost/?db=2')

Installing and Running

To install:

python setup.py install
pip install python-stdnet
easy_install python-stdnet

At the moment, only redis back-end is available, so to run tests you need to install redis. Once done that, launch redis and type:

python test.py

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

python-stdnet-0.3.1.tar.gz (53.6 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page