Esempio n. 1
0
def main():
    watcher_service.prepare_service(sys.argv)

    LOG.info(_LI('Starting Watcher Applier service in PID %s'), os.getpid())

    applier_service = watcher_service.Service(manager.ApplierManager)

    # Only 1 process
    launcher = watcher_service.launch(CONF, applier_service)
    launcher.wait()
Esempio n. 2
0
def main():
    watcher_service.prepare_service(sys.argv)

    LOG.info(_LI('Starting Watcher Applier service in PID %s'), os.getpid())

    applier_service = watcher_service.Service(manager.ApplierManager)

    # Only 1 process
    launcher = watcher_service.launch(CONF, applier_service)
    launcher.wait()
Esempio n. 3
0
def main():
    watcher_service.prepare_service(sys.argv, CONF)

    LOG.info('Starting Watcher Applier service in PID %s', os.getpid())

    applier_service = watcher_service.Service(manager.ApplierManager)

    syncer = sync.Syncer()
    syncer.sync()

    # Only 1 process
    launcher = watcher_service.launch(CONF, applier_service)
    launcher.wait()
Esempio n. 4
0
def main():
    watcher_service.prepare_service(sys.argv)

    LOG.info(_LI('Starting Watcher Decision Engine service in PID %s'),
             os.getpid())

    syncer = sync.Syncer()
    syncer.sync()

    de_service = watcher_service.Service(manager.DecisionEngineManager)
    bg_schedulder_service = scheduling.DecisionEngineSchedulingService()

    # Only 1 process
    launcher = watcher_service.launch(CONF, de_service)
    launcher.launch_service(bg_schedulder_service)

    launcher.wait()
Esempio n. 5
0
def main():
    watcher_service.prepare_service(sys.argv, CONF)
    gmr.register_gmr_plugins()

    LOG.info('Starting Watcher Decision Engine service in PID %s', os.getpid())

    syncer = sync.Syncer()
    syncer.sync()

    de_service = watcher_service.Service(manager.DecisionEngineManager)
    bg_scheduler_service = scheduling.DecisionEngineSchedulingService()

    # Only 1 process
    launcher = watcher_service.launch(CONF, de_service)
    launcher.launch_service(bg_scheduler_service)

    launcher.wait()
Esempio n. 6
0
def main():
    service.prepare_service(sys.argv, CONF)

    host, port = cfg.CONF.api.host, cfg.CONF.api.port
    protocol = "http" if not CONF.api.enable_ssl_api else "https"
    # Build and start the WSGI app
    server = service.WSGIService('watcher-api', CONF.api.enable_ssl_api)

    if host == '127.0.0.1':
        LOG.info('serving on 127.0.0.1:%(port)s, '
                 'view at %(protocol)s://127.0.0.1:%(port)s' %
                 dict(protocol=protocol, port=port))
    else:
        LOG.info('serving on %(protocol)s://%(host)s:%(port)s' %
                 dict(protocol=protocol, host=host, port=port))

    launcher = service.launch(CONF, server, workers=server.workers)
    launcher.wait()
Esempio n. 7
0
def main():
    service.prepare_service(sys.argv)

    host, port = cfg.CONF.api.host, cfg.CONF.api.port
    protocol = "http" if not CONF.api.enable_ssl_api else "https"
    # Build and start the WSGI app
    server = service.WSGIService(
        'watcher-api', CONF.api.enable_ssl_api)

    if host == '127.0.0.1':
        LOG.info(_LI('serving on 127.0.0.1:%(port)s, '
                     'view at %(protocol)s://127.0.0.1:%(port)s') %
                 dict(protocol=protocol, port=port))
    else:
        LOG.info(_LI('serving on %(protocol)s://%(host)s:%(port)s') %
                 dict(protocol=protocol, host=host, port=port))

    launcher = service.launch(CONF, server, workers=server.workers)
    launcher.wait()