Various updates to improve the architecture, and capture additional logs.