Scheduler refactor

Formalize the state machine for containers in the domain, and use a CQRS-style model for managing incoming state vs. outgoing requests.