persistent composites

Aaron Brady castironpi at gmail.com
Mon Jun 15 17:56:20 CEST 2009


On Jun 15, 5:45 am, "Diez B. Roggisch" <de... at nospam.web.de> wrote:
> Aaron Brady wrote:
> > Hi, please forgive the multi-posting on this general topic.
>
> > Some time ago, I recommended a pursuit of keeping 'persistent
> > composite' types on disk, to be read and updated at other times by
> > other processes.  Databases provide this functionality, with the
> > exception that field types in any given table are required to be
> > uniform.  Python has no such restriction.
>
> > I tried out an implementation of composite collections, specifically
> > lists, sets, and dicts, using 'sqlite3' as a persistence back-end.
> > It's significantly slower, but we might argue that attempting to do it
> > by hand classifies as a premature optimization; it is easy to optimize
> > debugged code.
>
> <snip/>
>
> Sounds like you are re-inventing the ZODB.
>
> Diez

Alright, Diez.  Here is some private consulting for free.

''Section 2.6.1:
The most common idiom that isn't caught by the ZODB is mutating a list
or dictionary''

My approach performs this for free.

The docs also don't mention interprocess communication, which is one
of the two primary functions that I satisfy in my approach.

The syntax is different, non-trivially so, and mine is more Pythonic.



More information about the Python-list mailing list