MCPcopy Create free account
hub / github.com/ModelEngine-Group/flexai / handle_server_tcp

Function handle_server_tcp

GPU-Virtual-Service/gpu-remoting/monitor.py:297–305  ·  view source on GitHub ↗
(conn, addr)

Source from the content-addressed store, hash-verified

295 #一开始先初始化redis里的服务器信息,然后启动TCP连接,监听Server请求
296 get_gpu_info()
297 config = load_runtime_config()
298
299 HOST = config['MonitorConfig']['monitorIp_']
300 PORT = config['MonitorConfig']['monitorPort_']
301 logging.debug(f"HOST: {HOST}, PORT: {PORT}")
302 logging.info("Server listening on")
303
304
305 # 启动GPU utilization数据收集线程
306 gpu_thread = threading.Thread(target=collect_gpu_utilization)
307 gpu_thread.daemon = True # 设置为守护线程,这样主线程结束时该线程也会结束
308 gpu_thread.start()

Callers

nothing calls this directly

Calls 2

handle_messageFunction · 0.70
closeMethod · 0.45

Tested by

no test coverage detected