tags:

views:

381

answers:

2

I keep seeing documentation saying that its not possible to send to a remote transactional msmq queue, outside the scope of a transaction. I'm finding this hard to believe because I think I've been doing exactly that for weeks now. I have a small app that posts messages to a remote queue that is transactional. Just to experiment with performance, various versions of the client have either used a TransactionScope to wrap the send operation or not. Ultimately, using some compensating transaction logic seemed a lot smarter and faster, so use of TransactionScope on both client and server were dropped. The thing is, messages still seem to show up on the queue, and get processed by the service without any problem.

Can anybody explain to me what it is that I'm missing here? Am I just being thick? Feel free to say so (it certainly won't be the first time).

+1  A: 

The transaction you refer to with the TransactionScope are implemented by the dtc ( distributed transaction coordinator). msmq (like sql) have its internal transaction engine. There is a property in the message that states that its a transactional message. And you probably set it somewhere in you code.

Igal Serban
A: 

It depends which version of MSMQ you're using. Only MSMQ 4.0 and above (Vista, 7, Server 2008) can do remote transactional reads. And you're using the TransactionScope correctly, as DTC must be used.

Luke