Transactional or non-transactional msmq

I continue to see documentation saying that it cannot be sent to the remote transactional queue msmq, which is outside the scope of the transaction. It’s hard for me to believe, because I think I’ve been doing this for several weeks now. I have a small application that sends messages to a remote queue, which is transactional. To experiment with performance, various client versions either used TransactionScope to transfer the send operation or not. Ultimately, using some compensatory transaction logic became much smarter and faster, so using TransactionScope on both clients and servers was discarded. The fact is that messages still appear in the queue and are processed by the service without any problems.

Can someone explain to me what it is that I'm missing here? Am I just fat? Feel free to talk about it (this, of course, will not be the first time).

+4
source share
2 answers

The transaction with which you refer to TransactionScope is implemented by dtc (Distributed Transaction Coordinator). msmq (e.g. sql) have an internal transaction mechanism. The message has a property indicating that it is a transactional message. And you probably install it somewhere in your code.

+4
source

It depends on which version of MSMQ you are using. Only MSMQ 4.0 and higher (Vista, 7, Server 2008) can perform remote transactional reads. And you are using TransactionScope correctly, as DTC should be used.

+1
source

All Articles