Distributed transaction support in wcf using WS-AT  
Author Message
lingga





PostPosted: Transactions Programming, Distributed transaction support in wcf using WS-AT Top

Hi all,

Could anybody knows where I could find the example of distributed transaction in wcf using ws-at So it enables 3rd party service (like IBM svc) to join the transactions.

Thank you in advance.

lingga



Software Development for Windows Vista13  
 
 
Jesse - MSFT





PostPosted: Transactions Programming, Distributed transaction support in wcf using WS-AT Top

Hi lingga, any WCF client/service using a binding with TransactionFlow enabled AND the transaction protocol set to WSAtomicTransactionOctober2004 will flow WS-AT on the wire (making interop possible). The user programming model stays the same for WS-AT and our native protocol. As an example, see below for how to flow WS-AT using WSHttpBinding and NetTcpBinding.

Documentation for WCF: http://wcf.netfx3.com/ -> Download Documentation CTP

Transaction Sample: Download above documenation and open 'wcf_samples.chm'. Goto Tech Samples -> Binding -> WS -> WS Transaction Flow.

[Using WSHttpBinding]

Code:

WSHttpBinding binding = new WSHttpBinding();

binding.TransactionFlow = true;

Config:

<bindings>

<wsHttpBinding>

<binding name="wsHttpBindingWSAT"

transactionFlow="true" />

</wsHttpBinding >

</bindings>

[Using NetTcpBinding]

Code:

NetTcpBinding binding = new NetTcpBinding();

binding.TransactionFlow = true;

binding.TransactionProtocol = TransactionProtocol.WSAtomicTransactionOctober2004;

Config:

<bindings>

<netTcpBinding>

<binding name="netTcpBindingWSAT"

transactionFlow="true"

transactionProtocol="WSAtomicTransactionOctober2004" />

</netTcpBinding>

</bindings>