event loop and event-driven async socket base class packaging