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
a6cf5de9
Commit
a6cf5de9
authored
Dec 24, 2018
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
aa23bcda
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
4 deletions
+3
-4
go/zodb/connection.go
go/zodb/connection.go
+3
-4
No files found.
go/zodb/connection.go
View file @
a6cf5de9
...
...
@@ -61,9 +61,8 @@ type Connection struct {
//
// but does not hold strong reference to cached objects.
//
// LiveCache is safe for multiple simultaneous read access.
// LiveCache is not safe for multiple simultaneous read/write access -
// the caller must explicitly serialize access with e.g. .Lock() .
// LiveCache is safe to access for multiple-readers / single-writer.
// To do so the caller must explicitly serialize access with e.g. .Lock() .
//
// XXX try to hide locking from user?
type
LiveCache
struct
{
...
...
@@ -170,7 +169,7 @@ func (e *wrongClassError) Error() string {
// Get lookups object corresponding to oid in the cache.
//
// I
t is not safe to call Get from multiple goroutines simultaneously
.
// I
f object is found, it is guaranteed to stay in live cache while the caller keeps reference to it
.
func
(
cache
*
LiveCache
)
Get
(
oid
Oid
)
IPersistent
{
wobj
:=
cache
.
objtab
[
oid
]
var
obj
IPersistent
...
...
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