Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Ws Wiki" for change 
notification.

The following page has been changed by KevinWilliams:
http://wiki.apache.org/ws/WorkingWithTransactions

------------------------------------------------------------------------------
  The second API used by clients is the DAS applyChanges() method (see 
ChangeSummaryProcessing).  Again, the boundaries of the transaction match the 
boundaries fo the call to the method. The DAS will create a set of 
INSERT/UPDATE and DELETE statments to flush the graph changes to the database 
and all of these statements will be executed as part of a single transaction.  
If the method returns without exception then the application can assume that 
all changes were successfully committed to the database.  If an exception is 
returned then the changes will have all been rolled back.
  
  == External Transactions ==
- To be continued...
+ The RDB DAS provides a straightforward mechanism for working with external 
transactions.  As mentioned above, the DAS, by default, acts as the transaction 
manager and commits and rolls back transactions accordingly.  However, that DAS 
can also be configured to not issue commit/rollback and this is the behavior 
needed to have the DAS participate in a larger transaction since some external 
party is responsible for these actions.  The following pseudo-code illustrates 
this:
  
+ {{{
+ tx.begin();
+ try {
+      doSomeJMSStuff();
+      doSomeDASStuff();
+       tx.commit();
+ } catch (AnyException ex) {
+      tx.rollback();
+ } 
+ }}}
+ 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to