--- a/src/pyams_scheduler/include.py Fri Jan 26 17:30:47 2018 +0100
+++ b/src/pyams_scheduler/include.py Thu Feb 08 08:54:58 2018 +0100
@@ -28,12 +28,11 @@
# import packages
from pyams_scheduler.process import SchedulerProcess, SchedulerMessageHandler
-from pyams_utils.registry import set_local_registry
+from pyams_utils.registry import set_local_registry, get_global_registry
from pyams_utils.zodb import get_connection_from_settings
from pyams_zmq.process import process_exit_func
from pyramid.events import subscriber
from pyramid.settings import asbool
-from zope.component.globalregistry import getGlobalSiteManager
def include_package(config):
@@ -59,7 +58,7 @@
if sys.argv[0].endswith('pyams_upgrade'):
return
- registry = getGlobalSiteManager()
+ registry = get_global_registry()
settings = registry.settings
start_handler = asbool(settings.get(SCHEDULER_STARTER_KEY, False))
if start_handler: