Commit b7010b29 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 89c810e4
......@@ -63,7 +63,7 @@ several client processes that use ZODB.
In shared-cache mode file's data is accessed through special filesystem for
which data cache is centrally maintained by OS kernel. This mode was added in
2020 and reduces wendelin.core RAM consumption dramatically. Note that even
2021 and reduces wendelin.core RAM consumption dramatically. Note that even
though the cache is shared, isolation property is still fully provided. Please
see wcfs/wcfs.go which describes the filesystem and shared-cache mode in detail.
......
......@@ -28,7 +28,6 @@ from BTrees.IOBTree import IOBTree
import transaction
from transaction import TransactionManager
from golang import defer, func
import weakref, gc
from pytest import raises
import pytest; xfail = pytest.mark.xfail
......
......@@ -159,8 +159,8 @@ def zconn_at(zconn): # -> tid
# We rely on our patch in 4-nxd branch that reworks ZODB.Connection to
# implement MVCC via always calling loadBefore(zconn._txn_time) to load objects.
elif zmajor == 4:
assert 'conn:MVCC-via-loadBefore-only' in ZODB.nxd_patches, \
"https://lab.nexedi.com/nexedi/ZODB/merge_requests/1"
_zassertHasNXDPatch('conn:MVCC-via-loadBefore-only',
"https://lab.nexedi.com/nexedi/ZODB/merge_requests/1")
if zconn._mvcc_storage:
raise NotImplementedError("Connection.at for IMVCCStorage is not implemented")
......@@ -180,6 +180,14 @@ def before2at(before): # -> at
return p64(u64(before) - 1)
# _zassertHasNXDPatch asserts that ZODB is patched with specified Nexedi-provided patch.
def _zassertHasNXDPatch(patch, details_link):
nxd_patches = getattr(ZODB, 'nxd_patches', set())
if patch not in nxd_patches:
raise AssertionError(
"ZODB%s is not patched with required Nexedi patch %r\n\tSee %s for details" %
(zmajor, patch, details_link))
# _zversion returns ZODB version object
def _zversion():
dzodb3 = pkg_resources.working_set.find(pkg_resources.Requirement.parse('ZODB3'))
......
......@@ -83,8 +83,7 @@ from six.moves.urllib.parse import urlsplit, urlunsplit
from .client._wcfs import \
PyWCFS as _WCFS, \
PyWatchLink as WatchLink, \
PyPinReq as PinReq \
PyWatchLink as WatchLink \
# Server represents running wcfs server.
......
......@@ -851,11 +851,6 @@ retry:
return make_pair(nil, E(err));
}
// TODO ensure f<foid>@ wconn.at exists - else we get pins to non-existing
// state from wcfs, pinner replies nak, wcfs sends SIGBUS.
// TODO -> better teach wcfs to reject "watch <foid> @at" for @at where f did not existed.
// (see test_wcfs_watch_before_create)
FileH f; bool ok;
tie(f, ok) = wconn._filehTab.get_(foid);
if (ok) {
......
......@@ -8,7 +8,6 @@ require (
github.com/johncgriffin/overflow v0.0.0-20211019200055-46fa312c352c
github.com/kisielk/og-rek v1.1.1-0.20210310094122-8def3d024dac
github.com/pkg/errors v0.9.1
github.com/stretchr/objx v0.3.0 // indirect
github.com/stretchr/testify v1.7.0
lab.nexedi.com/kirr/go123 v0.0.0-20210906140734-c9eb28d9e408
lab.nexedi.com/kirr/neo/go v0.0.0-20211004111643-c74a5a3cd0d0
......
This diff is collapsed.
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