I have an application that is running in multiple threads and using DTC with our SQL Server (2008R2). I'm getting this intermittent exception being thrown, it happens anywhere from 5 minutes to 6 hours after starting the application. Looks to be when a DTC transaction is aborted it fails when trying to close commands in the abstract batcher. Any help much appreciated.
Framework Version: v4.0.30319 Description: The process was terminated due to an unhandled exception. Exception Info: System.InvalidOperationException Stack: at System.Collections.Generic.Dictionary`2+KeyCollection+Enumerator[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].MoveNext() at NHibernate.AdoNet.AbstractBatcher.CloseCommands() at NHibernate.AdoNet.AbstractBatcher.Dispose(Boolean) at NHibernate.Impl.SessionImpl.Close() at NHibernate.Impl.SessionImpl.Dispose(Boolean) at NHibernate.Transaction.AdoNetWithDistributedTransactionFactory+<>c__DisplayClass1.<EnlistInDistributedTransactionIfNeeded>b__0(System.Object, System.Transactions.TransactionEventArgs) at System.Transactions.TransactionCompletedEventHandler.Invoke(System.Object, System.Transactions.TransactionEventArgs) at System.Transactions.TransactionStatePromotedAborted.EnterState(System.Transactions.InternalTransaction) at System.Transactions.InternalTransaction.DistributedTransactionOutcome(System.Transactions.InternalTransaction, System.Transactions.TransactionStatus) at System.Transactions.Oletx.RealOletxTransaction.FireOutcome(System.Transactions.TransactionStatus) at System.Transactions.Oletx.OutcomeEnlistment.InvokeOutcomeFunction(System.Transactions.TransactionStatus) at System.Transactions.Oletx.OletxTransactionManager.ShimNotificationCallback(System.Object, Boolean) at System.Threading._ThreadPoolWaitOrTimerCallback.PerformWaitOrTimerCallback(System.Object, Boolean) -- You received this message because you are subscribed to the Google Groups "nhusers" group. To view this discussion on the web visit https://groups.google.com/d/msg/nhusers/-/opaQ2HV89V8J. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/nhusers?hl=en.
