Last post Dec 05, 2012 05:55 PM by JORGEMAL
Dec 05, 2012 05:55 PM|JORGEMAL|LINK
I wonder if this post belongs here, please let me know if it does not.
I have a long process which performs several operations in a PostgreSQL database. Such a process was working fine until I included the TransactionScope class. This modification to my code did not represent a great deal because all I did was to enclose the
whole process within the TransactionScope.
The ADO.NET provider I use is a product from DevArt called "dotConnet for PostgreSQL" and there is also a DevArt tool called "DBMonitor" which let me monitor all of the DB operations. Running this tool I noticed that many connections to the DB are left open
in 2 operations that are performed by 2 C# recursive methods, a situation that does not happen when I take such recursive processes out of the TransactionScope. My problem is that, at a certain point, my web form stops running and I get a "Transport channel
is closed" message.
Is there any special consideration that I need to be aware of when running recursive code within a TransactionScope?
Any comments will be of great help.