예제 #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()
예제 #2
0
파일: applier.py 프로젝트: akinsWin/watcher
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()
예제 #3
0
파일: applier.py 프로젝트: sjamgade/watcher
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()
예제 #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()
예제 #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()
예제 #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()
예제 #7
0
파일: api.py 프로젝트: j-carpentier/watcher
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()