Beispiel #1
0
    def __init__(self):
        super(KuryrK8sService, self).__init__()

        objects.register_locally_defined_vifs()
        pipeline = h_pipeline.ControllerPipeline(self.tg)
        self.watcher = watcher.Watcher(pipeline, self.tg)
        self.health_manager = health.HealthServer()

        handlers = _load_kuryr_ctrlr_handlers()
        for handler in handlers:
            self.watcher.add(handler.get_watch_path())
            pipeline.register(handler)
Beispiel #2
0
    def __init__(self):
        super(KuryrK8sService, self).__init__()

        objects.register_locally_defined_vifs()
        pipeline = h_pipeline.ControllerPipeline(self.tg)
        self.watcher = watcher.Watcher(pipeline, self.tg)
        self.health_manager = health.HealthServer()
        # TODO(ivc): pluggable resource/handler registration
        for resource in ["pods", "services", "endpoints"]:
            self.watcher.add("%s/%s" % (constants.K8S_API_BASE, resource))
        pipeline.register(h_vif.VIFHandler())
        pipeline.register(h_lbaas.LBaaSSpecHandler())
        pipeline.register(h_lbaas.LoadBalancerHandler())
    def __init__(self):
        super(KuryrK8sService, self).__init__()
        periodic_task.PeriodicTasks.__init__(self, CONF)

        objects.register_locally_defined_vifs()
        pipeline = h_pipeline.ControllerPipeline(self.tg)
        self.watcher = watcher.Watcher(pipeline, self.tg, exit_on_stop=True)
        self.health_manager = health.HealthServer()
        self.current_leader = None
        self.node_name = utils.get_node_name()

        handlers = _load_kuryr_ctrlr_handlers()
        for handler in handlers:
            self.watcher.add(handler.get_watch_path())
            pipeline.register(handler)
        self.pool_driver = drivers.VIFPoolDriver.get_instance(
            specific_driver='multi_pool')
        self.pool_driver.set_vif_driver()
Beispiel #4
0
 def setUp(self):
     super(TestHealthServer, self).setUp()
     self.srv = health.HealthServer()
     self.srv.application.testing = True
     self.test_client = self.srv.application.test_client()