Closed gabrielanhaia closed 11 months ago
Hey there.
This is not 100% a request for a feature, but it might be interesting for some people to know (as for me).
I would like to know where you guys would wrap the database insertion into a transaction.
Looking at the project, my best guess would be here: https://github.com/CodelyTV/php-ddd-example/blob/835bc68b1559a0810168e25d0579d96f4f299deb/src/Shared/Infrastructure/Persistence/Doctrine/DoctrineRepository.php#L20
But I am not 100% sure.
Thanks a lot in advance, and feel free to close this issue if it is the wrong channel
Wrapping the Use Case or doing a middleware before the command handler. Something like this 🙂
Thanks a lot @rgomezcasas
Hey there.
This is not 100% a request for a feature, but it might be interesting for some people to know (as for me).
I would like to know where you guys would wrap the database insertion into a transaction.
Looking at the project, my best guess would be here: https://github.com/CodelyTV/php-ddd-example/blob/835bc68b1559a0810168e25d0579d96f4f299deb/src/Shared/Infrastructure/Persistence/Doctrine/DoctrineRepository.php#L20
But I am not 100% sure.
Thanks a lot in advance, and feel free to close this issue if it is the wrong channel