def __init__(self): self.__transmitter = Transmitter( HealthWorker, tcp_receiver=(CF.get("HealthMonitor", 'ip'), int(CF.get("HealthMonitor", 'tcp_port'))), name="health") self.__health_monitor = None
class Middleware(metaclass=Singleton): def __init__(self): self.__transmitter = Transmitter(MiddleWorker) # self.__db_mapper = None def start(self): self.__transmitter.start() def stop(self): self.__transmitter.stop()
class StorageManager(metaclass=Singleton): def __init__(self): self.__transmitter = Transmitter(StorageWorker) self.__health_monitor = None def start(self): self.__transmitter.start() # self.__health_monitor.start() def stop(self): self.__transmitter.stop()
class HealthManager(metaclass=Singleton): def __init__(self): self.__transmitter = Transmitter( HealthWorker, tcp_receiver=(CF.get("HealthMonitor", 'ip'), int(CF.get("HealthMonitor", 'tcp_port'))), name="health") self.__health_monitor = None def start(self): self.__transmitter.start(receivers=(base_tcp, None)) # self.__health_monitor.start() def stop(self): self.__transmitter.stop()
def __init__(self): self.__transmitter = Transmitter(StorageWorker) self.__health_monitor = None
def __init__(self): self.__transmitter = Transmitter(ClusterWorker) self.__health_monitor = None
def __init__(self): self.__transmitter = Transmitter(MiddleWorker)