Module twisted.popsicle.mailsicle
Mailsicle
A Reference Implementation of a Popsicle Back-End.
This is a very simple persistence mechanism that demonstrates various
things about the Popsicle persistence manager. It is very slow and its
scalability depends intimately on the performance characteristics of your
filesystem, so use with caution.
There are a few advantages to using Mailsicle for persistence,
however. Its fileformat is almost completely transparent: it uses an
RFC822-inspired (though by no means compliant!) fileformat for easy
inspection and manual repair. It provides very basic indexes, which is a
slight advantage over dirdbm+shelf persistence.
One slightly strange advantage is that it's somewhat tedious to write
persistence adapters for mailsicle. This provides a useful exercise in
locating the essential information that you want to persist, and can be a
useful prelude to developing an efficient relational schema for a set of
objects, while providing a fallback mechanism in the case where a
database is not installed.
Future Work:
-
optionally allow for backending to BSDDB or other single-file approach
instead of sprawling across filesystem, first for indexes, then for
content
Function Summary |
|
dictToHeaders(d)
|
|
getSaver(o,
repo)
|
|
headersToTuples(hdrs)
|
|
hexlify(s)
|
|
makeStringList(l)
|
|
parseOIDList(s)
|
|
parseStringList(s)
|
|
quotify(s)
|
|
unhexlify(s)
|
|
whitePrefix(s)
|
|
writeHeader(f,
k,
v)
|
IHeaderSaver
-
- Type:
-
MetaInterface
- Value:
<class 'twisted.popsicle.mailsicle.IHeaderSaver'>
|
|
Interface
-
- Type:
-
MetaInterface
- Value:
<class 'twisted.python.components.Interface'>
|
|
poidl
-
- Type:
-
SRE_Pattern
- Value:
(?:"((?:"|.)*?)" |)<([^>]*)>
|
|
psl
-
- Type:
-
SRE_Pattern
- Value:
|
wspr
-
- Type:
-
SRE_Pattern
- Value:
|