Monorepo for Aesthetic.Computer aesthetic.computer

Make piece-logs-cli exit instead of lingering forever master

Each invocation is a one-shot read-only lookup, but the process never exited: the Mongo driver keeps a handle alive past disconnect(), so main() resolving was not enough to drain the event loop. On lith 32 of these had piled up over three weeks — the oldest 20.6 days — holding ~890MB of a 4GB box, which is most of why its memory read as full. Exit explicitly once main resolves, and disconnect from a finally so a thrown query cannot leave the connection open either.


+19 -7
1 changed file