Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
e133164e
Commit
e133164e
authored
Dec 26, 2008
by
Tres Seaver
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove signal-driven pack cruft.
parent
92c8c0fa
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
21 deletions
+0
-21
lib/python/Signals/Signals.py
lib/python/Signals/Signals.py
+0
-21
No files found.
lib/python/Signals/Signals.py
View file @
e133164e
...
...
@@ -87,19 +87,6 @@ class LogfileRotateHandler:
handler
.
rotate
()
logger
.
info
(
"Log files rotation complete"
)
def
packHandler
():
""" Packs the main database. Not safe to call under a signal
handler, because it blocks the main thread """
logger
.
info
(
'Packing main ZODB database'
)
import
Globals
try
:
db
=
Globals
.
opened
[
0
]
db
.
pack
()
logger
.
info
(
'Database packing launched or completed successfully'
)
except
:
logger
.
exception
(
'Call to pack failed!'
)
def
registerZopeSignals
(
loggers
):
from
signal
import
SIGTERM
,
SIGINT
try
:
...
...
@@ -122,11 +109,3 @@ def registerZopeSignals(loggers):
# no restart handler on windows.
# Log files get 'rotated', not 'reopened'
SignalHandler
.
registerHandler
(
SIGUSR2
,
LogfileRotateHandler
(
loggers
))
# SIGUSR1 is nominally reserved for pack, but we dont have an
# implementation that is stable yet because if the signal handler
# fires it will be caught in the main thread and all network operations
# will cease until it's finished.
# (The above is *not* True for Windows - a different thread is used to
# catch the signals. This probably could be switched on for Windows
# if anyone cares)
#SignalHandler.registerHandler(SIGUSR1, packHandler)
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