Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
neo
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Kirill Smelkov
neo
Commits
351d5dfa
Commit
351d5dfa
authored
Mar 17, 2021
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
49581d4b
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
4 deletions
+10
-4
go/zodb/storage/demo/demo.go
go/zodb/storage/demo/demo.go
+10
-4
No files found.
go/zodb/storage/demo/demo.go
View file @
351d5dfa
...
...
@@ -19,6 +19,9 @@
// Package demo provides overlayed storage, similar to DemoStorage in ZODB/py.
//
// Storage combines base and δ storages as if δ transactional log was logically
// appended to base.
//
// XXX
// XXX link to DemoStorage
package
demo
...
...
@@ -59,8 +62,12 @@ func (d *Storage) Close() error {
}
// Sync implements zodb.IStorageDriver .
func
(
d
*
Storage
)
Sync
(
ctx
context
.
Context
)
(
head
zodb
.
Tid
,
_
error
)
{
// XXX errctx?
func
(
d
*
Storage
)
Sync
(
ctx
context
.
Context
)
(
head
zodb
.
Tid
,
err
error
)
{
defer
func
()
{
if
err
!=
nil
{
err
=
&
zodb
.
OpError
{
URL
:
d
.
URL
(),
Op
:
"sync"
,
Args
:
xid
,
Err
:
err
}
}
}()
head
,
err
:=
d
.
δ
.
Sync
(
ctx
)
if
err
!=
nil
{
...
...
@@ -136,8 +143,7 @@ func (d *Storage) Load(ctx context.Context, xid zodb.Xid) (_ *mem.Buf, _ zodb.Ti
// Iterator implements zodb.IStorageDriver .
func
(
d
*
Storage
)
Iterate
(
ctx
context
.
Context
,
tidMin
,
tidMax
zodb
.
Tid
)
zodb
.
ITxnIterator
{
// XXX errctx?
panic
(
"TODO"
)
// XXX
panic
(
"TODO"
)
}
// URL implements zodb.IStorageDriver .
...
...
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