Behavior of EnlistDistributedTransaction(null)

  • Thread starter Thread starter Jim Young
  • Start date Start date
J

Jim Young

Hi,

Can someone tell me what actually happens when I call
EnlistDistributedTransaction(null) on SqlConnection object?

Is it supposed to unenlist?

Or is it supposed to enlist in the transaction of the
current transaction context? If so, what will happen if
there is no transation context?

Thanks!

Jim
 
¤ Hi,
¤
¤ Can someone tell me what actually happens when I call
¤ EnlistDistributedTransaction(null) on SqlConnection object?
¤
¤ Is it supposed to unenlist?
¤
¤ Or is it supposed to enlist in the transaction of the
¤ current transaction context? If so, what will happen if
¤ there is no transation context?

I would check the documentation:

http://msdn.microsoft.com/library/d...ionclassenlistdistributedtransactiontopic.asp


Paul ~~~ (e-mail address removed)
Microsoft MVP (Visual Basic)
 
Paul,

Thanks for the link.

However, the reason I have posted this question here is
due to the fact that the documentation does not describe
the what the beavhior should be when null is passed to
EnlistDistributedTransaction. If you know the answer to
my question(s), please let me know.

Thanks,

Jim
-----Original Message-----
 
Jim,
This is the first question I see regarding EnlistDistributedTransactions, I
was beginning to think that nobody was using DTC at all. I am very
interested in finding out more about how you are using this feature and
Distributed Transactions in general. We are working on a very major
Distributed Transactions enhancement for the next release of the framework
in the shape of the System.Transactions namespace that shipped in very bare
bones form with the Whidbey alpha and I am looking for any likely customers
of this feature.

Calling EnlistDistributedTransaction(null) unenlists the connection from its
current transaction context. I don't really like this behavior at all and I
would have much preferred an API where a connection once enlisted continues
being enlisted for the lifetime of the transaction, is there any user
scenario you can think of where unenlisting from a DTC makes sense?

Thanks,
 
¤ Paul,
¤
¤ Thanks for the link.
¤
¤ However, the reason I have posted this question here is
¤ due to the fact that the documentation does not describe
¤ the what the beavhior should be when null is passed to
¤ EnlistDistributedTransaction. If you know the answer to
¤ my question(s), please let me know.
¤

Sorry about that. I think I just made the assumption based upon behavior described in the
documentation.


Paul ~~~ (e-mail address removed)
Microsoft MVP (Visual Basic)
 
Back
Top