Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
ZEO
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
ZEO
Commits
fb7b9b4d
Commit
fb7b9b4d
authored
Aug 27, 2001
by
Shane Hathaway
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Got cache_detail and cache_extreme_detail working again and added links
from the debugging information screen.
parent
8375ad9f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
8 deletions
+14
-8
src/ZODB/DB.py
src/ZODB/DB.py
+14
-8
No files found.
src/ZODB/DB.py
View file @
fb7b9b4d
...
...
@@ -84,8 +84,8 @@
##############################################################################
"""Database objects
$Id: DB.py,v 1.3
2 2001/05/22 23:01:45 jeremy
Exp $"""
__version__
=
'$Revision: 1.3
2
$'
[
11
:
-
2
]
$Id: DB.py,v 1.3
3 2001/08/27 19:25:19 shane
Exp $"""
__version__
=
'$Revision: 1.3
3
$'
[
11
:
-
2
]
import
cPickle
,
cStringIO
,
sys
,
POSException
,
UndoLogCompatible
from
Connection
import
Connection
...
...
@@ -237,22 +237,28 @@ class DB(UndoLogCompatible.UndoLogCompatible):
def
cacheExtremeDetail
(
self
):
detail
=
[]
def
f
(
con
,
detail
=
detail
,
rc
=
sys
.
getrefcount
):
conn_no
=
[
0
]
# A mutable reference to a counter
def
f
(
con
,
detail
=
detail
,
rc
=
sys
.
getrefcount
,
conn_no
=
conn_no
):
conn_no
[
0
]
=
conn_no
[
0
]
+
1
cn
=
conn_no
[
0
]
for
oid
,
ob
in
con
.
_cache
.
items
():
id
=
oid
id
=
''
if
hasattr
(
ob
,
'__dict__'
):
d
=
ob
.
__dict__
if
d
.
has_key
(
'id'
):
id
=
"%s (%s)"
%
(
oid
,
d
[
'id'
])
id
=
d
[
'id'
]
elif
d
.
has_key
(
'__name__'
):
id
=
"%s (%s)"
%
(
oid
,
d
[
'__name__'
])
id
=
d
[
'__name__'
]
detail
.
append
({
'oid'
:
id
,
'conn_no'
:
cn
,
'oid'
:
oid
,
'id'
:
id
,
'klass'
:
"%s.%s"
%
(
ob
.
__class__
.
__module__
,
ob
.
__class__
.
__name__
),
'rc'
:
rc
(
ob
)
-
4
,
'references'
:
con
.
references
(
oid
),
'state'
:
ob
.
_p_changed
,
#'references': con.references(oid),
})
self
.
_connectionMap
(
f
)
...
...
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