customserver: preemtively run GC before starting room (#3637)
GC seems to be lazy.
This commit is contained in:
parent
eaec41d885
commit
187f9dac94
|
@ -325,6 +325,7 @@ def run_server_process(name: str, ponyconfig: dict, static_server_data: dict,
|
|||
def run(self):
|
||||
while 1:
|
||||
next_room = rooms_to_run.get(block=True, timeout=None)
|
||||
gc.collect(0)
|
||||
task = asyncio.run_coroutine_threadsafe(start_room(next_room), loop)
|
||||
self._tasks.append(task)
|
||||
task.add_done_callback(self._done)
|
||||
|
|
Loading…
Reference in New Issue