public function __construct(EntityManager $entityManager, EventLog $eventLog, CommandBusFactory $commandBusFactory) { $this->products = new ORMProducts($entityManager); $this->commandBus = $this->createCommandBus($commandBusFactory, $eventLog, [new TransactionExtension(new ORMFactory($entityManager))]); }