Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
wendelin.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
Kirill Smelkov
wendelin.core
Commits
8e049dd2
Commit
8e049dd2
authored
Nov 16, 2021
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
9e6a2f9a
Changes
12
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
22 additions
and
56 deletions
+22
-56
bigfile/file_zodb.py
bigfile/file_zodb.py
+4
-3
lib/tests/test_zodb.py
lib/tests/test_zodb.py
+0
-1
lib/zodb.py
lib/zodb.py
+10
-2
wcfs/__init__.py
wcfs/__init__.py
+1
-2
wcfs/client/client_test.py
wcfs/client/client_test.py
+0
-1
wcfs/client/wcfs.cpp
wcfs/client/wcfs.cpp
+0
-5
wcfs/client/wcfs_watchlink.cpp
wcfs/client/wcfs_watchlink.cpp
+0
-2
wcfs/go.mod
wcfs/go.mod
+1
-2
wcfs/go.sum
wcfs/go.sum
+2
-34
wcfs/internal/xbtree/xbtreetest/init/init.go
wcfs/internal/xbtree/xbtreetest/init/init.go
+1
-1
wcfs/wcfs.go
wcfs/wcfs.go
+1
-1
wcfs/wcfs_test.py
wcfs/wcfs_test.py
+2
-2
No files found.
bigfile/file_zodb.py
View file @
8e049dd2
...
...
@@ -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
202
0
and reduces wendelin.core RAM consumption dramatically. Note that even
202
1
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.
...
...
@@ -602,8 +602,9 @@ class ZBigFile(LivePersistent):
# More: the algorythm to compute δ(ZODB) -> δ(blk) is more complex
# than 1-1 ZBlk <-> blk mapping: ZBlk could stay constant, but if
# ZBigFile.blktab topology is changed, affected file blocks have to
# be invalidated. Currently both !wcfs and wcfs codepaths fail to
# handle that, but wcfs will be improved and !wcfs will be deprecated.
# be invalidated. Currently !wcfs codepath fails to handle that,
# while wcfs handles invalidations correctly. The plan is to make
# wcfs way the primary and to deprecate !wcfs.
#
# -> don't propagate ZODB -> WCFS invalidation by client to fully
# rely on and test wcfs subsystem.
...
...
lib/tests/test_zodb.py
View file @
8e049dd2
...
...
@@ -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
...
...
lib/zodb.py
View file @
8e049dd2
...
...
@@ -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
\
t
See %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'
))
...
...
wcfs/__init__.py
View file @
8e049dd2
...
...
@@ -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.
...
...
wcfs/client/client_test.py
View file @
8e049dd2
...
...
@@ -36,7 +36,6 @@ from wendelin.wcfs.internal.wcfs_test import read_mustfault
from
wendelin.wcfs.internal
import
mm
from
pytest
import
raises
from
golang.golang_test
import
panics
import
os
,
multiprocessing
,
gc
...
...
wcfs/client/wcfs.cpp
View file @
8e049dd2
...
...
@@ -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
)
{
...
...
wcfs/client/wcfs_watchlink.cpp
View file @
8e049dd2
...
...
@@ -17,8 +17,6 @@
// See COPYING file for full licensing terms.
// See https://www.nexedi.com/licensing for rationale and options.
#include "wcfs_misc.h"
#include "wcfs.h"
#include "wcfs_watchlink.h"
#include <golang/errors.h>
...
...
wcfs/go.mod
View file @
8e049dd2
...
...
@@ -5,10 +5,9 @@ go 1.14
require (
github.com/golang/glog v1.0.0
github.com/hanwen/go-fuse/v2 v2.1.0 // replaced to -> kirr/go-fuse@y/nodefs-cancel
github.com/johncgriffin/overflow v0.0.0-20
170615021017-4d914c927216
github.com/johncgriffin/overflow v0.0.0-20
211019200055-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
...
...
wcfs/go.sum
View file @
8e049dd2
This diff is collapsed.
Click to expand it.
wcfs/internal/xbtree/xbtreetest/init/init.go
View file @
8e049dd2
...
...
@@ -22,7 +22,7 @@
// xbtreetest at runtime.
package
init
// ZBlk-related part of
δbtail_
test
// ZBlk-related part of
xbtree
test
import
(
"context"
...
...
wcfs/wcfs.go
View file @
8e049dd2
...
...
@@ -954,7 +954,7 @@ retry:
for
sk
:=
range
gdebug
.
zheadSockTab
{
_
,
err
:=
fmt
.
Fprintf
(
xio
.
BindCtxW
(
sk
,
ctx
),
"%s
\n
"
,
δZ
.
Tid
)
if
err
!=
nil
{
log
.
Errorf
(
"zhead: %s: write: %s (detaching reader)"
,
sk
,
err
)
log
.
Errorf
(
"zhead: %s: write: %s (detaching reader)"
,
sk
.
file
,
err
)
sk
.
Close
()
delete
(
gdebug
.
zheadSockTab
,
sk
)
}
...
...
wcfs/wcfs_test.py
View file @
8e049dd2
...
...
@@ -367,6 +367,8 @@ class tWCFS(_tWCFS):
go
(
t
.
_abort_ontimeout
,
t
.
_wcfuseabort
,
10
*
time
.
second
,
nogilready
)
# NOTE must be: with_timeout << · << wcfs_pin_timeout
nogilready
.
recv
()
# wait till _abort_ontimeout enters nogil
# _abort_ontimeout is in wcfs_test.pyx
# close closes connection to wcfs, unmounts the filesystem and makes sure
# that wcfs server exits.
@
func
...
...
@@ -440,8 +442,6 @@ class tDB(tWCFS):
def
head
(
t
):
return
t
.
dFtail
[
-
1
].
rev
# _abort_ontimeout is in wcfs_test.pyx
# close closes test database as well as all tracked files, watch links and wcfs.
# it also prints change history to help developer overview current testcase.
@
func
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment