extractor to convert a total function into a partial function internally _
A CommandToInvoker is a PartialFunction from a Command to a CommandHandlerInvoker
An EventHandler is a PartialFunction from an Event to an aggregate
An EventHandler is a PartialFunction from an Event to an aggregate
Typically it is used to construct or update an aggregate. In case of update, an Aggregate instance must be in scope.