public function append($aDomainEvent)
{
$storedEvent = new StoredEvent(get_class($aDomainEvent), $aDomainEvent->occurredOn(), $this->serializer()->serialize($aDomainEvent, 'json'));
$this->getEntityManager()->persist($storedEvent);
$this->getEntityManager()->flush($storedEvent);
}