Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
neoppod
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Levin Zimmermann
neoppod
Commits
c3fd8cf3
Commit
c3fd8cf3
authored
Jul 30, 2018
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
e38d6b5a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
2 deletions
+21
-2
go/zodb/db.go
go/zodb/db.go
+4
-0
go/zodb/zodb.go
go/zodb/zodb.go
+17
-2
No files found.
go/zodb/db.go
View file @
c3fd8cf3
...
...
@@ -43,6 +43,7 @@ type DB struct {
connv
[]
*
Connection
// order by ↑= .at
// information about invalidations
// XXX -> Storage. XXX or -> Cache? (so it is not duplicated many times for many DB case)
invTab
[]
invEntry
// order by ↑= .tid
}
...
...
@@ -81,10 +82,13 @@ func (db *DB) Open(ctx context.Context) (*Connection, error) {
}
// wait till .invTab is up to date covering ≥ lastTid
// XXX reenable
/*
err = db.invTab.Wait(ctx, at)
if err != nil {
return nil, err
}
*/
// now we have both at and invalidation data covering it -> proceed to
// get connection from the pool.
...
...
go/zodb/zodb.go
View file @
c3fd8cf3
...
...
@@ -328,6 +328,16 @@ type IStorageDriver interface {
Loader
Iterator
// Notifier returns storage driver notifier.
//
// The notifier represents invalidation channel (notify about changes
// made to DB not by us from outside). XXX
//
// To simplify drivets, there must be only 1 logical user of
// storage-driver level notifier interface. Ccontrary IStorage allows
// for several users of notification channel. XXX ok?
Notifier
()
Notifier
}
// Loader provides functionality to load objects.
...
...
@@ -391,9 +401,14 @@ type Committer interface {
}
// Notifier allows to be notified of
database changes mad
e by other clients.
// Notifier allows to be notified of
changes made to databas
e by other clients.
type
Notifier
interface
{
// TODO: invalidation channel (notify about changes made to DB not by us from outside)
// Read returns next notification event.
//
// XXX ...
// XXX overflow -> special error
Read
(
ctx
context
.
Context
)
(
Tid
,
[]
Oid
,
error
)
}
...
...
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