Commit d27c89ee authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent c042f7ae
...@@ -23,7 +23,10 @@ ...@@ -23,7 +23,10 @@
# distutils: language=c++ # distutils: language=c++
"""Modules _file_zodb.pyx complements file_zodb.py with things that cannot be """Modules _file_zodb.pyx complements file_zodb.py with things that cannot be
implemented in Python.""" implemented in Python.
It provides wcfs integration for ZBigFile handles opened with _use_wcfs=True.
"""
from __future__ import print_function, absolute_import from __future__ import print_function, absolute_import
...@@ -80,7 +83,7 @@ cdef public class _ZBigFile(BigFile) [object _ZBigFile, type _ZBigFile_Type]: ...@@ -80,7 +83,7 @@ cdef public class _ZBigFile(BigFile) [object _ZBigFile, type _ZBigFile_Type]:
return obj return obj
def __dealloc__(_ZBigFile zf): def __dealloc__(_ZBigFile zf):
zf.wfileh = nil zf.wfileh = nil # XXX where it should be closed?
# redirect load/store to main class # redirect load/store to main class
...@@ -88,8 +91,9 @@ cdef public class _ZBigFile(BigFile) [object _ZBigFile, type _ZBigFile_Type]: ...@@ -88,8 +91,9 @@ cdef public class _ZBigFile(BigFile) [object _ZBigFile, type _ZBigFile_Type]:
def storeblk(self, blk, buf): return self.zself.storeblk(blk, buf) def storeblk(self, blk, buf): return self.zself.storeblk(blk, buf)
# blkmmapper is pycapsule with virtmem mmap functions for _ZBigFile. # blkmmapper complemnts loadblk/storeblk and is pycapsule with virtmem mmap
# The functions rely on .wfileh being initialized by .fileh_open() # functions for _ZBigFile. MMap functions rely on .wfileh being initialized
# by .fileh_open()
blkmmapper = PyCapsule_New(<void*>&ZBigFile_mmap_ops, "wendelin.bigfile.IBlkMMapper", NULL) blkmmapper = PyCapsule_New(<void*>&ZBigFile_mmap_ops, "wendelin.bigfile.IBlkMMapper", NULL)
# fileh_open wraps BigFile.fileh_open and makes sure that WCFS file handle # fileh_open wraps BigFile.fileh_open and makes sure that WCFS file handle
......
...@@ -594,14 +594,6 @@ class ZBigFile(LivePersistent): ...@@ -594,14 +594,6 @@ class ZBigFile(LivePersistent):
zblk.bindzfile(self, blk) zblk.bindzfile(self, blk)
# blkmmapper complemnts loadblk/storeblk and returns object with pycapsule with .mmap*
# methods to be used by virtmem to mmap base overlay of the file data. XXX text
def blkmmapper(self):
# XXX return wcfileh (= zconn.wconn.open(self._p_oid))
1/0
# invalidate data .blktab[blk] invalidated -> invalidate page # invalidate data .blktab[blk] invalidated -> invalidate page
def invalidateblk(self, blk): def invalidateblk(self, blk):
for fileh in self._v_filehset: for fileh in self._v_filehset:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment