TransactionScope escalation
Hi
We were excited by the potential of TransactionScope to simplify our data access code, eliminating the need to pass around a database transaction.After playing around with .NET 2.0 for a while we were very disappointed to find that unless you used the exact same connection object and kept it open for the duration of the transaction it would result in escalation to the DTC, even though all connections were to the same resource and using the same connection string.
This leaves passing a connection around or creating a DbConnectionScope (mentioned in one of the forum post below) as the only option to avoid escalation. This is a little less than an ideal situation.
This problem has been discussed pretty extensively in the two threads below.
http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=113669&SiteID=1
http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=531830&SiteID=1
Jian Zeng from Microsoft test mentions in the first thread that it is a known issue and will be fixed in a later release.
This problem is a major road block to using TransactionScope in a real project. I would love to hear other peoples thoughts. Is this an issue for you too?
Thanks Joel
Vote on this issue here.
https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=171884

