aspnetrun/run-aspnetcore-microservices

Transaction in ordering

DavoodRm opened this issue · 1 comments

hi
How do I create a transaction in the handle?
Given that OrderDbContext is in the Infrastructure layer.
Transactions can be managed using Behaviours, but I do not have access to Infrastructure in the application layer

If your transaction is only in ordering microservice, then you can implement uow in the Infrastructure layer.
But if transactions need to touch several microservices then things are going to complicate more, so we can apply a saga pattern.