system.transactions

Inner TransactionScope with different IsolationLevel, how can it be achieved?

柔情痞子 提交于 2020-06-27 15:54:09
问题 The current implementation of TransactionScope lacks the ability to change IsolationLevels in nested scopes. MSDN states: When using nested TransactionScope objects, all nested scopes must be configured to use exactly the same isolation level if they want to join the ambient transaction. If a nested TransactionScope object tries to join the ambient transaction yet it specifies a different isolation level, an ArgumentException is thrown. However SQL Server allows us to change Isolation Levels

TransactionScope throws TransactionAbortedException when Disposed

岁酱吖の 提交于 2020-01-17 03:55:28
问题 I have the following scenario: Parent process start TransactionScope, a token identifying the transaction is created using TransactionInterop.GetTransmitterPropagationToken, inserts data to database. TransactionScope completes. Another process is started, using the above mentioned token it creates Transaction which is then used to create TransactionScope. This process also inserts data to database. TransactionScope completes and is disposed. Parent process tries to dispose its

TransactionScope throws TransactionAbortedException when Disposed

限于喜欢 提交于 2020-01-17 03:55:26
问题 I have the following scenario: Parent process start TransactionScope, a token identifying the transaction is created using TransactionInterop.GetTransmitterPropagationToken, inserts data to database. TransactionScope completes. Another process is started, using the above mentioned token it creates Transaction which is then used to create TransactionScope. This process also inserts data to database. TransactionScope completes and is disposed. Parent process tries to dispose its

SqlClient.SqlTransaction vs System.Transactions

谁说我不能喝 提交于 2019-12-24 14:37:34
问题 We have some constant issues with MSDTC setting up, now considering replacing SystemTransactions with SqlTransactions . I am interested in differences of the above, and possible issues we might have doing that. 回答1: The article quoted and referenced by Massimiliano was 7 years old when referenced and therefore refers only to .NET 2.0 and SQL Server 2000 and 2005. However, I believe the salient points are still valid for later versions. I'm having trouble finding directly applicable commentary

.net durable resource manager for transactional filesystem access

白昼怎懂夜的黑 提交于 2019-12-18 05:56:08
问题 I'm trying to wrap my head around the use of the System.Transactions namespace in C#. I've found some documentation on MSDN regarding using resource managers, but it only covers volatile, in-memory resource managers in any detail (like Transactional ). I'm basically looking for something that I can use inside of a TransactionScope, just like Transactional<> but use it for writing/modifying/deleting files on disk. Does something like this exist in the standard libs? I've read that NTFS has

SQL CE 4 System.Transaction support

跟風遠走 提交于 2019-12-12 16:57:21
问题 A similar question was asked here but had no answer. I am attempting to use a System.Transactions.CommittableTransaction with EF CTP4 and SQL CE 4. I have created the following transaction attribute for my ASP.NET MVC Controller actions: public class TransactionAttribute : ActionFilterAttribute { CommittableTransaction transaction; public override void OnActionExecuting(ActionExecutingContext filterContext) { transaction = new CommittableTransaction(); Transaction.Current = transaction; base

Using transactions across processes

佐手、 提交于 2019-12-11 01:55:25
问题 I'm trying to use System.Transactions (TransactionScope) to coordinate a set of processes, each of which does some database work. Ultimately all processes need to commit or be rolled back atomically via one parent process. Unfortunately, nothing I've tried so far works. My basic strategy is to TransactionScope in the parent process, save it to a file, and invoke a child process, which loads the file, uses the transaction inside its own TransactionScope, and returns to the parent. But this

Trace why a transaction is escalated to DTC

别等时光非礼了梦想. 提交于 2019-12-08 15:07:31
问题 Is there any way to determine precisely why a System.Transaction TrasactionScope is being escalated to the DTC? We are hitting a bump with one of our components that seem to escalate the transaction while all other components (which seem deceptively similar) does not do escalation. Are any information made available on the reasons for the escalation and how can they be found and observed? SQL Profiler? Log files? Or am I out of luck on this one? UPDATE: I'm running against SQL Server 2005 for

TransactionScope across AppDomains and processes

北战南征 提交于 2019-12-07 06:05:49
问题 Is it real to use System.Transactions (primarily TransactionScope) across different AppDomains and processes? DependentTransaction works only inside one AppDomain. 回答1: Yes, it works. We are flowing transactions via WCF, calling out of process transactional COM+ components, and manually passing transactions from a .NET 2.0 asmx web service to a WCF service. Now that is not to say that the setup is not finicky. I think most of the issues were around getting MSDTC set up properly on all the

TransactionScope across AppDomains and processes

半世苍凉 提交于 2019-12-05 11:22:04
Is it real to use System.Transactions (primarily TransactionScope) across different AppDomains and processes? DependentTransaction works only inside one AppDomain. Yes, it works. We are flowing transactions via WCF, calling out of process transactional COM+ components, and manually passing transactions from a .NET 2.0 asmx web service to a WCF service. Now that is not to say that the setup is not finicky. I think most of the issues were around getting MSDTC set up properly on all the servers. UPDATE We don't use DependentClone . We are passing the transaction as a byte array using