Module ocean
|
|
Lock
|
|
|
TransactionCache
|
|
|
Ocean
This storage works based on records stored in a hashtable The id
must be hashable Internally, there is a long list of records and an
index table which contains references to where these records are
|
|
|
TestOcean
|
|
|
__VERSION__ = '0.2.1'
|
|
|
__HEADER_FORMAT__ = '=2c8s'
|
|
|
__EXTENDED_HEADER_FORMAT__ = '=c'
|
|
|
__TAU__ = 20
|
|
|
sz__HEADER_FORMAT__ = calcsize(__HEADER_FORMAT__)
|
|
|
sz__EXTENDED_HEADER_FORMAT__ = calcsize(__EXTENDED_HEADER_FORM...
|
|
|
HF_S = Struct(__HEADER_FORMAT__)
|
|
|
HF_U = HF_S.unpack
|
|
|
HF_P = HF_S.pack
|
|
|
EHF_S = Struct(__EXTENDED_HEADER_FORMAT__)
|
|
|
EHF_U = EHF_S.unpack
|
|
|
EHF_P = EHF_S.pack
|
|
|
INDEX_S = Struct("=37sII0I")
|
|
|
INDEX_U = INDEX_S.unpack
|
|
|
INDEX_P = INDEX_S.pack
|
Imports:
sys,
os,
unittest,
getopt,
OOBTree,
persistent,
TimeStamp,
Struct,
calcsize,
get_ip_address,
CURRENT_DIR,
main_is_frozen,
read_config,
setup_json_protocol,
StringIO,
UserDict,
dropwhile,
chain,
ifilter,
thread,
threading,
Queue,
pickle,
time,
copy,
neurons,
cache,
portalocker,
diskindex,
traceback,
pprint,
logging
sz__EXTENDED_HEADER_FORMAT__
- Value:
calcsize(__EXTENDED_HEADER_FORMAT__)
|
|