User Tools

Site Tools


csharp:aspnet:webapi

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

csharp:aspnet:webapi [2013/06/23 14:45]
rtavassoli [Polymorphism]
csharp:aspnet:webapi [2013/06/23 14:54] (current)
rtavassoli [Polymorphism]
Line 41: Line 41:
 The same effect can be obtained by having separate handlers for different commands. However, I((not everyone, especially not the people rejecting distributed transactions)) believe in batching commands, and guaranteeing to the user that either all will pass or fail. And when sticking to SQL Server 2008 or higher, no distributed transactions are needed for this, even if the commands go to different databases inside the same datebase server. The same effect can be obtained by having separate handlers for different commands. However, I((not everyone, especially not the people rejecting distributed transactions)) believe in batching commands, and guaranteeing to the user that either all will pass or fail. And when sticking to SQL Server 2008 or higher, no distributed transactions are needed for this, even if the commands go to different databases inside the same datebase server.
 > >
-Without batching, you will either have to build composite commands or workflow engines. The problem with composite commands is that the same //smaller// command can now be part of more than one command, and system maintenance will suffer. The problem with workflow engines((or //SAGAs//)) is that they are complicated, and should not have to be used in simple cases where a user wants to change a name and the bithday together, and if one of those fails, having to implement a complicated workflow to compensate for that. A simple transactional handling two separate commands is so much simpler((KISS, n'est ce pas?)).+Without batching, you will either have to build composite commands or workflow engines. The problem with composite commands is that the same //smaller// command can now be part of more than one command, and system maintenance will suffer. The problem with workflow engines((or //SAGAs//)) is that they are complicated, and should not have to be used in simple cases where a user wants to change a name and the bithday together, and if one of those fails, having to implement a complicated workflow to compensate for that. A simple transaction handling two separate commands is so much easier((KISS, n'est ce pas?)).
csharp/aspnet/webapi.1371991522.txt.gz ยท Last modified: 2013/06/23 14:45 by rtavassoli