I have a command in my .NET webservice which needs to save information in several different places:
- 1 local database SQL Server using Entity Framework
- 2 different webservices using REST
I would like to use the Unit Of Work pattern. It's easy when you only have a database and work with the data context.
But do you have any idea how I can implement a Unit Of Work with mixed targets? I know that I cannot rely on a distributed transaction and I can live without. But the principle of Unit Of Work is something I would like to keep.
Any idea, advice or pattern I could use for that?
Aucun commentaire:
Enregistrer un commentaire