I am using NServiceBus with Distributed Transactions. Normally this works fantastic. Either my message succeeds or fails. All or nothing.
However, I am also trying to record diagnostic data to my database. This is done on a separate ObjectContext. For that, I would like it to save to the database regardless of the success or failure of the Distributed Transaction.
Is there a way to have one (and only one) data context connect to the database outside the distributed transaction? (And keep the rest of them in?)
Try this to suppress your ambient distributed transaction for auditing: