LoggerDomainEventSubscriber.php coupled to infrastructure at domain layer
Opened this issue · 0 comments
borjapazr commented
The LoggerDomainEventSubscriber.php is located in the Domain layer. In addition, it uses functionalities specific to the Infrastructure layer, such as Monolog or Elastica.
Wouldn't it be more appropriate and consistent with the principles dictated by DDD to create a contract (interface) of the Logger in Domain layer, implement it in the Infrastructure layer and then create a subscriber of the domain events in the Application layer?
Thanks in advance 😊