Cleanup
Bring session watcher inside accept loop
Break up into smaller logical files
Split activity drain into a function
Refactoring

Most notably, this introduces some app state in preparation for
exposing this state via WebSockets on the http side.