def main(HOST=MiningTCPServer.DefaultListenAddr, PORT=MiningTCPServer.DefaultListenPort):
    addtional = MiningMasterController()
    addtional.start()
    print("host running at: " + HOST + " port: " + str(PORT))
    # Create the server, binding to localhost on port 9999
    server = MiningTCPServer((HOST, PORT), MasterRequestHandler, arg=addtional)
    server.serve_forever()
def main(HOST=MiningTCPServer.DefaultListenAddr, PORT=MiningTCPServer.DefaultListenPort):
    addtional = SiteCheckProcessManager(max_procss=2)
    addtional.start()
    print("slave running at: " + HOST + " port: " + str(PORT))
    # Create the server, binding to localhost on port 9999
    server = MiningTCPServer((HOST, PORT), MiningRequestHandler, arg=addtional)
    server.serve_forever()
def main(HOST=MiningTCPServer.DefaultListenAddr,
         PORT=MiningTCPServer.DefaultListenPort):
    addtional = SiteCheckProcessManager(max_procss=2)
    addtional.start()
    print("slave running at: " + HOST + " port: " + str(PORT))
    # Create the server, binding to localhost on port 9999
    server = MiningTCPServer((HOST, PORT), MiningRequestHandler, arg=addtional)
    server.serve_forever()
def abstract_main(server_handler: ServerRequestHandler,
                  HOST=MiningTCPServer.DefaultListenAddr,
                  PORT=MiningTCPServer.DefaultListenPort):
    server_handler.start()
    print("server running at: " + HOST + " port: " + str(PORT))
    # Create the server, binding to localhost on port 9999
    server = MiningTCPServer((HOST, PORT),
                             SimpleServerHandler,
                             arg=server_handler)
    server.serve_forever()