OW2 Consortium
Search OW2 Mail Archive: 

Advanced Search - Powered by Google


Mail Archive Home | gotm-commits List | August 2005 Index

<--  Date Index  --> <--  Thread Index  -->

CVS update of gotm-jts (20 files)


    Date: Friday, August 12, 2005 @ 14:31:26
  Author: rouvoy
    Path: /cvsroot/gotm/gotm-jts

   Added: 
src/fractal/org/objectweb/gotm/lib/FcAdaptiveTransactionFactory.fractal
           src/fractal/org/objectweb/gotm/lib/FcResourceManager.fractal
          src/fractal/org/objectweb/gotm/lib/FcTransaction.fractal
          src/java/org/objectweb/gotm/lib/jta/TransactionCurrent.java
          src/java/org/objectweb/gotm/lib/jta/UserTransactionImpl.java
Modified: .settings/org.eclipse.core.resources.prefs
          examples/benchmark/.cvsignore examples/benchmark/build.xml
          
examples/benchmark/src/java/org/objectweb/benchmark/jts/Benchmark2PC.java
          
          
examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkAPC.java
          
          
examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkJTS.java
          
          
examples/benchmark/src/java/org/objectweb/benchmark/jts/CommitProtocolIteratable.java
          
          
examples/benchmark/src/java/org/objectweb/benchmark/jts/XAResourceIteratable.java
           src/fractal/org/objectweb/gotm/lib/JtsTransaction.fractal
          src/fractal/org/objectweb/gotm/lib/JtsTransactionManager.fractal
          src/java/org/objectweb/gotm/lib/JtsFactory.java
          src/java/org/objectweb/gotm/lib/jta/TransactionManagerImpl.java
 Removed: 
src/fractal/org/objectweb/gotm/lib/JtsAdaptiveTransactionManager.fractal
           src/fractal/org/objectweb/gotm/lib/TpResourceManager.fractal
          src/fractal/org/objectweb/gotm/lib/TpTransaction.fractal

* Replacing template ADL declaration by classic Fractal ADL declaration.
* Implicit support of template components.
* Support of UserTransaction as current.
* Support for dynamic adaptability.
* Updating performance benchmark.
* Removing unused utils components.


---------------------------------------------------------------------------------------+
 .settings/org.eclipse.core.resources.prefs                                   
         |    8 
 examples/benchmark/.cvsignore                                                
         |    1 
 examples/benchmark/build.xml                                                 
         |   10 
 examples/benchmark/src/java/org/objectweb/benchmark/jts/Benchmark2PC.java    
         |   20 -
 examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkAPC.java    
         |   38 -
 examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkJTS.java    
         |   24 -
 
examples/benchmark/src/java/org/objectweb/benchmark/jts/CommitProtocolIteratable.java
 |   20 -
 
examples/benchmark/src/java/org/objectweb/benchmark/jts/XAResourceIteratable.java
     |   14 
 src/fractal/org/objectweb/gotm/lib/FcAdaptiveTransactionFactory.fractal      
         |   13 
 src/fractal/org/objectweb/gotm/lib/FcResourceManager.fractal                 
         |   58 ++
 src/fractal/org/objectweb/gotm/lib/FcTransaction.fractal                     
         |   69 +++
 src/fractal/org/objectweb/gotm/lib/JtsAdaptiveTransactionManager.fractal     
         |   25 -
 src/fractal/org/objectweb/gotm/lib/JtsTransaction.fractal                    
         |   34 -
 src/fractal/org/objectweb/gotm/lib/JtsTransactionManager.fractal             
         |   26 -
 src/fractal/org/objectweb/gotm/lib/TpResourceManager.fractal                 
         |   60 ---
 src/fractal/org/objectweb/gotm/lib/TpTransaction.fractal                     
         |   77 ---
 src/java/org/objectweb/gotm/lib/JtsFactory.java                              
         |   12 
 src/java/org/objectweb/gotm/lib/jta/TransactionCurrent.java                  
         |   51 ++
 src/java/org/objectweb/gotm/lib/jta/TransactionManagerImpl.java              
         |  171 +-------
 src/java/org/objectweb/gotm/lib/jta/UserTransactionImpl.java                 
         |  195 ++++++++++
 20 files changed, 516 insertions(+), 410 deletions(-)


Index: gotm-jts/.settings/org.eclipse.core.resources.prefs
diff -u gotm-jts/.settings/org.eclipse.core.resources.prefs:1.9 
gotm-jts/.settings/org.eclipse.core.resources.prefs:1.10
--- gotm-jts/.settings/org.eclipse.core.resources.prefs:1.9     Mon Aug  8 
15:30:05 2005
+++ gotm-jts/.settings/org.eclipse.core.resources.prefs Fri Aug 12 14:31:26 
2005
@@ -1,4 +1,4 @@
-#Thu Aug 04 14:17:21 CEST 2005
+#Fri Aug 12 13:16:53 CEST 2005
 eclipse.preferences.version=1
 
encoding//examples/benchmark/src/fractal/org/objectweb/benchmark/FcBenchmark2PC.fractal=ISO-8859-1
 
encoding//examples/benchmark/src/fractal/org/objectweb/benchmark/FcBenchmarkAPC.fractal=ISO-8859-1
@@ -6,8 +6,8 @@
 
encoding//examples/local/src/fractal/org/objectweb/gotm/jts/local/FcApplication.fractal=ISO-8859-1
 
encoding//examples/local/src/fractal/org/objectweb/gotm/jts/local/FcExplorer.fractal=ISO-8859-1
 
encoding//examples/local/src/fractal/org/objectweb/gotm/lib/FcLocalExplorer.fractal=ISO-8859-1
-encoding//src/fractal/org/objectweb/gotm/lib/JtsAdaptiveTransactionManager.fractal=ISO-8859-1
+encoding//src/fractal/org/objectweb/gotm/lib/FcAdaptiveTransactionFactory.fractal=ISO-8859-1
+encoding//src/fractal/org/objectweb/gotm/lib/FcResourceManager.fractal=ISO-8859-1
+encoding//src/fractal/org/objectweb/gotm/lib/FcTransaction.fractal=ISO-8859-1
 
encoding//src/fractal/org/objectweb/gotm/lib/JtsTransaction.fractal=ISO-8859-1
 
encoding//src/fractal/org/objectweb/gotm/lib/JtsTransactionManager.fractal=ISO-8859-1
-encoding//src/fractal/org/objectweb/gotm/lib/TpResourceManager.fractal=ISO-8859-1
-encoding//src/fractal/org/objectweb/gotm/lib/TpTransaction.fractal=ISO-8859-1
Index: gotm-jts/examples/benchmark/.cvsignore
diff -u gotm-jts/examples/benchmark/.cvsignore:1.2 
gotm-jts/examples/benchmark/.cvsignore:1.3
--- gotm-jts/examples/benchmark/.cvsignore:1.2  Mon Aug  8 15:29:01 2005
+++ gotm-jts/examples/benchmark/.cvsignore      Fri Aug 12 14:31:26 2005
@@ -1,2 +1,3 @@
 output
 bench-apc.txt
+benchmark-jts.txt
Index: gotm-jts/examples/benchmark/build.xml
diff -u gotm-jts/examples/benchmark/build.xml:1.3 
gotm-jts/examples/benchmark/build.xml:1.4
--- gotm-jts/examples/benchmark/build.xml:1.3   Mon Aug  8 15:29:02 2005
+++ gotm-jts/examples/benchmark/build.xml       Fri Aug 12 14:31:26 2005
@@ -21,7 +21,7 @@
 <!-- Initial developer(s): Romain Rouvoy.                                 -->
 <!-- Contributor(s): ______________________________________.              -->
 
-<!-- $Id: build.xml,v 1.3 2005/08/08 13:29:02 rouvoy Exp $ -->
+<!-- $Id: build.xml,v 1.4 2005/08/12 12:31:26 rouvoy Exp $ -->
 <!-- ==================================================================== -->
 
 <project name="JTS Benchmark" default="all">
@@ -71,7 +71,7 @@
     </jar>
   </target>
 
-  <target name="import" depends="bench-build,clear"/>
+  <target name="import" depends="bench-build,clear" unless="imported"/>
   
   <target name="execute" depends="import"
    description="execute All Benchmarks">
@@ -81,7 +81,7 @@
     <antcall target="execute-jts"/>
   </target>
   
-  <target name="execute-jts" depends="import" unless="imported"
+  <target name="execute-jts" depends="import"
    description="execute JTS Benchmark">
     <property name="julia.cfg" value="${build.dir}/${lib.dir}/julia.cfg"/>
     <property name="cache.cfg"  value="${build.dir}/${lib.dir}/cache.cfg"/>
@@ -99,7 +99,7 @@
     </java>
   </target>
 
-  <target name="execute-2pc" depends="import" unless="imported"
+  <target name="execute-2pc" depends="import"
    description="execute Commit Protocol Benchmark">
     <property name="julia.cfg" value="${build.dir}/${lib.dir}/julia.cfg"/>
     <property name="cache.cfg"  value="${build.dir}/${lib.dir}/cache.cfg"/>
@@ -117,7 +117,7 @@
     </java>
   </target>
 
-  <target name="execute-apc" depends="import" unless="imported"
+  <target name="execute-apc" depends="import"
    description="execute Adaptive Commit Protocol Benchmark">
     <property name="julia.cfg" value="${build.dir}/${lib.dir}/julia.cfg"/>
     <property name="cache.cfg"  value="${build.dir}/${lib.dir}/cache.cfg"/>
Index: 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/Benchmark2PC.java
diff -u 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/Benchmark2PC.java:1.1
 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/Benchmark2PC.java:1.2
--- 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/Benchmark2PC.java:1.1
      Mon Aug  8 15:29:02 2005
+++ 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/Benchmark2PC.java
  Fri Aug 12 14:31:26 2005
@@ -22,7 +22,7 @@
  Contributor(s): ______________________________________.
 
  ---------------------------------------------------------------------
- $Id: Benchmark2PC.java,v 1.1 2005/08/08 13:29:02 rouvoy Exp $
+ $Id: Benchmark2PC.java,v 1.2 2005/08/12 12:31:26 rouvoy Exp $
  ====================================================================*/
 
 package org.objectweb.benchmark.jts;
@@ -46,8 +46,8 @@
 /**
  * @author <a href="mailto:Romain.Rouvoy@xxxxxxx";>Romain Rouvoy</a>
  * @created 3 janv. 2005
- * @modified $Date: 2005/08/08 13:29:02 $
- * @version $Revision: 1.1 $
+ * @modified $Date: 2005/08/12 12:31:26 $
+ * @version $Revision: 1.2 $
  * @fractal.itf name="runnable" signature="java.lang.Runnable"
  */
 public class Benchmark2PC
@@ -56,13 +56,13 @@
     /** <code>MIN</code> . */
     public static int MIN = 0 ;
     /** <code>MAX</code> . */
-    public static int MAX = 100 ;
+    public static int MAX = 60 ;
     /** <code>STEP</code> . */
     public static int STEP = 2 ;
     /** <code>WARM</code> . */
-    public static int WARM = 10 ;
+    public static int WARM = 1 ;
     /** <code>BENCH</code> . */
-    public static int BENCH = 100 ;
+    public static int BENCH = 10 ;
     
     
     /*
@@ -73,9 +73,9 @@
     public void run() {
         System.out.println("[2PC] Configuring the transaction services...");
         Map tm = new HashMap();
-        tm.put("GoTM-2PC", "org.objectweb.gotm.lib.protocol.Tp2PC");
-        tm.put("GoTM-2PCPA", "org.objectweb.gotm.lib.protocol.Tp2PCPA");
-        tm.put("GoTM-2PCPC", "org.objectweb.gotm.lib.protocol.Tp2PCPC");
+        tm.put("GoTM-2PC", "org.objectweb.gotm.lib.protocol.Fc2PC");
+        tm.put("GoTM-2PCPA", "org.objectweb.gotm.lib.protocol.Fc2PCPA");
+        tm.put("GoTM-2PCPC", "org.objectweb.gotm.lib.protocol.Fc2PCPC");
         
         System.out.println("[2PC] Configuring the benchmark...");
         Scenario commit1 = new TransactionScenarioXACommit("commit(true)");
@@ -96,7 +96,7 @@
 
         System.out.println("[2PC] Running Scenarios...");
         try {
-            scenario.run().accept(new VisitorWriter(new 
FileWriter("benchmark-2pc.txt")));
+            scenario.run().accept(new VisitorWriter(new 
FileWriter("output/benchmark-2pc.txt")));
         } catch (Exception e) {
             e.printStackTrace();
         }
Index: 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkAPC.java
diff -u 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkAPC.java:1.1
 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkAPC.java:1.2
--- 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkAPC.java:1.1
      Mon Aug  8 15:29:02 2005
+++ 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkAPC.java
  Fri Aug 12 14:31:26 2005
@@ -22,7 +22,7 @@
  Contributor(s): ______________________________________.
 
  ---------------------------------------------------------------------
- $Id: BenchmarkAPC.java,v 1.1 2005/08/08 13:29:02 rouvoy Exp $
+ $Id: BenchmarkAPC.java,v 1.2 2005/08/12 12:31:26 rouvoy Exp $
  ====================================================================*/
 
 package org.objectweb.benchmark.jts;
@@ -46,45 +46,43 @@
 /**
  * @author <a href="mailto:Romain.Rouvoy@xxxxxxx";>Romain Rouvoy</a>
  * @created 3 janv. 2005
- * @modified $Date: 2005/08/08 13:29:02 $
- * @version $Revision: 1.1 $
+ * @modified $Date: 2005/08/12 12:31:26 $
+ * @version $Revision: 1.2 $
  * @fractal.itf name="runnable" signature="java.lang.Runnable"
  */
 public class BenchmarkAPC
         extends LoggablePrimitive
         implements Runnable {
     /** <code>MIN</code> . */
-    public static int ITER = 200 ;
+    public static int ITER = 150 ;
     /** <code>STEP</code> . */
-    public static int STEP = 20 ;
+    public static int STEP = 15 ;
     /** <code>WARM</code> . */
-    public static int WARM = 1 ;
+    public static int WARM = 0 ;
     /** <code>BENCH</code> . */
-    public static int BENCH = 4 ;
+    public static int BENCH = 2 ;
     
-    /** <code>DESC</code> Descriptor of the Adaptive Transaction Manager to 
use. */
-    private static final String DESC = 
"org.objectweb.gotm.lib.JtsAdaptiveTransactionManager";
-
     /*
      * (non-Javadoc)
      * 
      * @see java.lang.Runnable#run()
      */
     public void run() {
-        Map context = new HashMap();
         Map configs = new HashMap();
         
         System.out.println("[APC] Configuring the transaction services...");
-        
context.put("communication","org.objectweb.gotm.lib.event.TpEventBusThread");
-        context.put("protocol", "org.objectweb.gotm.lib.protocol.Tp2PC");
-        configs.put("GoTM", JtsFactory.create(context));
-        context.put("protocol", "org.objectweb.gotm.lib.protocol.Tp2PC");
-        configs.put("GoTM-2PC", JtsFactory.create(context));
-        context.put("protocol", "org.objectweb.gotm.lib.protocol.Tp2PCPA");
+        Map context = new HashMap();
+        
System.getProperties().put("communication","org.objectweb.gotm.lib.event.FcEventBusThread");
+        
context.put("factory","org.objectweb.gotm.lib.factory.FcTransactionFactoryCache");
+        System.getProperties().put("protocol", 
"org.objectweb.gotm.lib.protocol.Fc2PCPA");
         configs.put("GoTM-2PCPA", JtsFactory.create(context));
-        context.put("protocol", "org.objectweb.gotm.lib.protocol.Tp2PCPC");
+        System.getProperties().put("protocol", 
"org.objectweb.gotm.lib.protocol.Fc2PCPC");
         configs.put("GoTM-2PCPC", JtsFactory.create(context));
-        configs.put("GoTM-SAPC", JtsFactory.create(DESC, new HashMap()));
+        System.getProperties().put("protocol", 
"org.objectweb.gotm.lib.protocol.Fc2PC");
+        configs.put("GoTM", JtsFactory.create(context));
+        configs.put("GoTM-2PC", JtsFactory.create(context));
+        
context.put("factory","org.objectweb.gotm.lib.FcAdaptiveTransactionFactory");
+        configs.put("GoTM-APC", JtsFactory.create(context));
         Iterable commit_protocols = new 
JavaTransactionServiceIteratable(configs);
         
         System.out.println("[APC] Configuring the benchmark...");
@@ -95,7 +93,7 @@
 
         System.out.println("[APC] Running Scenarios...");
         try {
-            scenario.run().accept(new VisitorDecorator(new VisitorWriter(new 
FileWriter("benchmark-apc.txt"))));
+            scenario.run().accept(new VisitorDecorator(new VisitorWriter(new 
FileWriter("output/benchmark-apc.txt"))));
         } catch (Exception e) {
             e.printStackTrace();
         }
Index: 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkJTS.java
diff -u 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkJTS.java:1.1
 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkJTS.java:1.2
--- 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkJTS.java:1.1
      Mon Aug  8 15:29:02 2005
+++ 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/BenchmarkJTS.java
  Fri Aug 12 14:31:26 2005
@@ -22,7 +22,7 @@
  Contributor(s): ______________________________________.
 
  ---------------------------------------------------------------------
- $Id: BenchmarkJTS.java,v 1.1 2005/08/08 13:29:02 rouvoy Exp $
+ $Id: BenchmarkJTS.java,v 1.2 2005/08/12 12:31:26 rouvoy Exp $
  ====================================================================*/
 
 package org.objectweb.benchmark.jts;
@@ -50,8 +50,8 @@
 /**
  * @author <a href="mailto:Romain.Rouvoy@xxxxxxx";>Romain Rouvoy</a>
  * @created 3 janv. 2005
- * @modified $Date: 2005/08/08 13:29:02 $
- * @version $Revision: 1.1 $
+ * @modified $Date: 2005/08/12 12:31:26 $
+ * @version $Revision: 1.2 $
  * @fractal.itf name="runnable" signature="java.lang.Runnable"
  */
 public class BenchmarkJTS
@@ -60,13 +60,13 @@
     /** <code>MIN</code> . */
     public static int MIN = 0 ;
     /** <code>MAX</code> . */
-    public static int MAX = 50000 ;
+    public static int MAX = 50 ;
     /** <code>STEP</code> . */
-    public static int STEP = 50 ;
+    public static int STEP = 1 ;
     /** <code>WARM</code> . */
     public static int WARM = 10 ;
     /** <code>BENCH</code> . */
-    public static int BENCH = 100 ;
+    public static int BENCH = 1000 ;
     
     
     /*
@@ -78,9 +78,12 @@
         Map tm = new HashMap();
         Map ctx = new HashMap() ;
         System.out.println("[JTS] Configuring the transaction services...");
-        
ctx.put("communication","org.objectweb.gotm.lib.event.TpEventBusSimple");
-        ctx.put("protocol", "org.objectweb.gotm.lib.protocol.Tp2PCNoLog");
-        tm.put("GoTM", JtsFactory.create(ctx));
+//        
ctx.put("current","org.objectweb.gotm.lib.current.FcCurrentManagerImpl");
+//        tm.put("GoTM-NoCache", JtsFactory.create(ctx));
+        
System.getProperties().put("protocol","org.objectweb.gotm.lib.protocol.Fc2PCNoLog");
+        
System.getProperties().put("communication","org.objectweb.gotm.lib.event.FcEventBusSimple");
+        
ctx.put("factory","org.objectweb.gotm.lib.factory.FcTransactionFactoryCache");
+        tm.put("GoTM-Cache", JtsFactory.create(ctx));
         Jotm jotm = null;
         try {
             jotm = new Jotm(true, false);
@@ -99,9 +102,10 @@
                 MIN, MAX, STEP));
         scenario = new ConfigurationIterator(scenario, tmi, new 
VisitorRename(
                 (Rename) tmi));
+        
         System.out.println("[JTS] Running Scenarios...");
         try {
-            scenario.run().accept(new VisitorWriter(new 
FileWriter("benchmark-jts.txt")));
+            scenario.run().accept(new VisitorWriter(new 
FileWriter("output/benchmark-jts.txt")));
         } catch (Exception e) {
             e.printStackTrace();
         }
Index: 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/CommitProtocolIteratable.java
diff -u 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/CommitProtocolIteratable.java:1.1
 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/CommitProtocolIteratable.java:1.2
--- 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/CommitProtocolIteratable.java:1.1
  Mon Aug  8 15:29:02 2005
+++ 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/CommitProtocolIteratable.java
      Fri Aug 12 14:31:26 2005
@@ -23,7 +23,7 @@
  Contributor(s): .
 
  ---------------------------------------------------------------------
- $Id: CommitProtocolIteratable.java,v 1.1 2005/08/08 13:29:02 rouvoy Exp $
+ $Id: CommitProtocolIteratable.java,v 1.2 2005/08/12 12:31:26 rouvoy Exp $
  ====================================================================*/
 package org.objectweb.benchmark.jts;
 
@@ -39,8 +39,8 @@
 /**
  * @author <a href="mailto:Romain.Rouvoy@xxxxxxx";>Romain Rouvoy</a>
  * @created 19 juil. 2005
- * @modified $Date: 2005/08/08 13:29:02 $
- * @version $Revision: 1.1 $
+ * @modified $Date: 2005/08/12 12:31:26 $
+ * @version $Revision: 1.2 $
  * @fractal.itf
  */
 public class CommitProtocolIteratable
@@ -56,16 +56,16 @@
      */
     public CommitProtocolIteratable(Map tm) {
         this.tx_manager = new HashMap();
-        Map ctx = new HashMap();
-        ctx.put("communication",
-                "org.objectweb.gotm.lib.event.TpEventBusThread");
+        Map context = new HashMap();
+        
context.put("factory","org.objectweb.gotm.lib.factory.FcTransactionFactoryCache");
+        
System.getProperties().put("communication","org.objectweb.gotm.lib.event.FcEventBusThread");
         
         for (Iterator i=tm.entrySet().iterator();i.hasNext();) {
             Entry e = (Entry) i.next();
             System.out.println("[JTS] Loading the "+e.getKey()+" 
configuration ["+e.getValue()+"]...");
             String protocol = (String) e.getValue();
-            ctx.put("protocol", protocol);
-            this.tx_manager.put(e.getKey(), JtsFactory.create(ctx));
+            System.getProperties().put("protocol", protocol);
+            this.tx_manager.put(e.getKey(), JtsFactory.create(context));
         }
     }
 
@@ -92,8 +92,8 @@
      * 
      * @author <a href="mailto:Romain.Rouvoy@xxxxxxx";>Romain Rouvoy</a>
      * @created 4 août 2005
-     * @modified $Date: 2005/08/08 13:29:02 $
-     * @version $Revision: 1.1 $
+     * @modified $Date: 2005/08/12 12:31:26 $
+     * @version $Revision: 1.2 $
      * @fractal.itf
      */
     private class CommitProtocolIterator
Index: 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/XAResourceIteratable.java
diff -u 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/XAResourceIteratable.java:1.1
 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/XAResourceIteratable.java:1.2
--- 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/XAResourceIteratable.java:1.1
      Mon Aug  8 15:29:02 2005
+++ 
gotm-jts/examples/benchmark/src/java/org/objectweb/benchmark/jts/XAResourceIteratable.java
  Fri Aug 12 14:31:26 2005
@@ -23,7 +23,7 @@
 Contributor(s): .
 
 ---------------------------------------------------------------------
-$Id: XAResourceIteratable.java,v 1.1 2005/08/08 13:29:02 rouvoy Exp $
+$Id: XAResourceIteratable.java,v 1.2 2005/08/12 12:31:26 rouvoy Exp $
 ====================================================================*/
 package org.objectweb.benchmark.jts;
 
@@ -39,8 +39,8 @@
 /**
  * @author <a href="mailto:Romain.Rouvoy@xxxxxxx";>Romain Rouvoy</a>
  * @created 19 juil. 2005
- * @modified $Date: 2005/08/08 13:29:02 $
- * @version $Revision: 1.1 $
+ * @modified $Date: 2005/08/12 12:31:26 $
+ * @version $Revision: 1.2 $
  * @fractal.itf name="xa-resource-iterable"
  */
 public class XAResourceIteratable
@@ -48,7 +48,7 @@
     /** <code>SWITCH</code> sequence size of the configuration to create 
with the failure flag. */
     public static final int SWITCH = 4;
     final int first,last,step;
-    boolean fails=true,random=false;
+    boolean fails=true,random=true;
     
     /**
      * @param first
@@ -59,7 +59,6 @@
         this.first = first ;
         this.last = last ;
         this.step = step ;
-        this.random = true;
     }
     
     /**
@@ -71,6 +70,7 @@
     public XAResourceIteratable(int first, int last, int step, boolean 
fails) {
         this(first,last,step);
         this.fails = fails;   
+        this.random = false;
     }
 
     /* (non-Javadoc)
@@ -84,8 +84,8 @@
      * XA Resource Generator & Iterator implementation.
      * @author <a href="mailto:Romain.Rouvoy@xxxxxxx";>Romain Rouvoy</a>
      * @created 4 août 2005
-     * @modified $Date: 2005/08/08 13:29:02 $
-     * @version $Revision: 1.1 $
+     * @modified $Date: 2005/08/12 12:31:26 $
+     * @version $Revision: 1.2 $
      * @fractal.itf 
      */
     private class XAResourceIterator implements Iterator {
Index: 
gotm-jts/src/fractal/org/objectweb/gotm/lib/FcAdaptiveTransactionFactory.fractal
diff -u /dev/null 
gotm-jts/src/fractal/org/objectweb/gotm/lib/FcAdaptiveTransactionFactory.fractal:1.1
--- /dev/null   Fri Aug 12 14:31:27 2005
+++ 
gotm-jts/src/fractal/org/objectweb/gotm/lib/FcAdaptiveTransactionFactory.fractal
    Fri Aug 12 14:31:26 2005
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!DOCTYPE definition PUBLIC 
+          "-//objectweb.org//DTD Fractal ADL 2.0//EN" 
+          "classpath://org/objectweb/fractal/adl/xml/standard.dtd">
+
+<definition name="org.objectweb.gotm.lib.FcAdaptiveTransactionFactory" 
extends="org.objectweb.gotm.lib.factory.FcTransactionFactory" 
arguments="descriptor">
+  <component name="FcFactory" 
definition="org.objectweb.gotm.lib.factory.FcTransactionFactoryAdaptive(${descriptor})"/>
+  <component name="FcProbe" 
definition="org.objectweb.gotm.lib.coordination.FcProbeCommitProtocol"/>
+
+  <binding client="this.transaction-factory" 
server="FcFactory.transaction-factory"/>
+  <binding client="FcFactory.publish"        server="FcProbe.publish"/>
+  <binding client="FcProbe.configurable"     
server="FcFactory.configurable"/>
+</definition>
\ No newline at end of file
Index: gotm-jts/src/fractal/org/objectweb/gotm/lib/FcResourceManager.fractal
diff -u /dev/null 
gotm-jts/src/fractal/org/objectweb/gotm/lib/FcResourceManager.fractal:1.1
--- /dev/null   Fri Aug 12 14:31:27 2005
+++ gotm-jts/src/fractal/org/objectweb/gotm/lib/FcResourceManager.fractal     
  Fri Aug 12 14:31:26 2005
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!DOCTYPE definition PUBLIC 
+          "-//objectweb.org//DTD Fractal ADL 2.0//EN" 
+          "classpath://org/objectweb/fractal/adl/xml/standard.dtd">
+
+<definition name="org.objectweb.gotm.lib.FcResourceManager" 
arguments="ResLog">
+  <interface name="synchronization" role="server"
+        signature="org.objectweb.gotm.lib.resource.ResourceManager"/>
+  <interface name="xa-resource" role="server"
+        signature="org.objectweb.gotm.lib.resource.ResourceManager"/>
+
+  <interface name="subscribe" role="client"
+        signature="org.objectweb.transaction.api.event.SubscribeFeature"/>
+  <interface name="tx-state" role="client"
+        
signature="org.objectweb.transaction.api.transaction.TransactionState"/>
+  <interface name="xid-provider" role="client"
+        signature="org.objectweb.gotm.lib.xid.XidFeature"/>
+  <interface name="vote-log" role="client"
+        signature="org.objectweb.transaction.api.logging.LoggerFeature"/>
+  <interface name="commit-ack-log" role="client"
+        signature="org.objectweb.transaction.api.logging.LoggerFeature"/>
+  <interface name="abort-ack-log" role="client"
+        signature="org.objectweb.transaction.api.logging.LoggerFeature"/>
+
+  <component name="FcSynchronizationManager" 
+       definition="org.objectweb.gotm.lib.resource.FcResourceManagerImpl"/>
+  <component name="FcSynchronizationActions"
+       
definition="org.objectweb.gotm.lib.jta.FcSynchronizationActionProvider"/>
+
+  <component name="FcXAResourceManager" 
+       definition="org.objectweb.gotm.lib.resource.FcResourceManagerImpl"/>
+  <component name="FcXAResourceActions"
+       
definition="org.objectweb.gotm.lib.jta.xa.FcXAResourceActionProvider"/>
+<!--
+  <component name="FcThread"
+       definition="org.objectweb.util.thread.comp.FcThreadManager(10,100)"/>
+  <binding client="FcSynchronizationManager.runnable-manager"
+           server="FcThread.runnable-manager"/>
+  <binding client="FcXAResourceManager.runnable-manager"
+           server="FcThread.runnable-manager"/>
+-->
+
+  <binding client="this.synchronization" 
server="FcSynchronizationManager.resource"/>
+  <binding client="this.xa-resource"     
server="FcXAResourceManager.resource"/>
+
+  <binding client="FcSynchronizationManager.action-provider"
+           server="FcSynchronizationActions.action-provider"/>
+  <binding client="FcSynchronizationManager.subscribe" 
server="this.subscribe"/>
+  <binding client="FcSynchronizationManager.tx-state"  
server="this.tx-state"/>
+
+  <binding client="FcXAResourceManager.action-provider" 
server="FcXAResourceActions.action-provider"/>
+  <binding client="FcXAResourceManager.subscribe"       
server="this.subscribe"/>
+  <binding client="FcXAResourceManager.tx-state"        
server="this.tx-state"/>
+  <binding client="FcXAResourceActions.xid-provider"    
server="this.xid-provider"/>
+  <binding client="FcXAResourceActions.vote-log"        
server="this.vote-log"/>
+  <binding client="FcXAResourceActions.commit-ack-log"  
server="this.commit-ack-log"/>
+  <binding client="FcXAResourceActions.abort-ack-log"   
server="this.abort-ack-log"/>
+</definition>
\ No newline at end of file
Index: gotm-jts/src/fractal/org/objectweb/gotm/lib/FcTransaction.fractal
diff -u /dev/null 
gotm-jts/src/fractal/org/objectweb/gotm/lib/FcTransaction.fractal:1.1
--- /dev/null   Fri Aug 12 14:31:27 2005
+++ gotm-jts/src/fractal/org/objectweb/gotm/lib/FcTransaction.fractal   Fri 
Aug 12 14:31:26 2005
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!DOCTYPE definition PUBLIC 
+          "-//objectweb.org//DTD Fractal ADL 2.0//EN"
+          "classpath://org/objectweb/fractal/adl/xml/standard.dtd">
+
+<definition name="org.objectweb.gotm.lib.FcTransaction" 
arguments="protocol,communication">
+  <interface name="tx-state" role="server" 
+        
signature="org.objectweb.transaction.api.transaction.TransactionState"/>
+  <interface name="one-pc" role="server"
+        
signature="org.objectweb.transaction.api.coordination.CoordinationFeature"/>
+  <interface name="two-pc" role="server"
+        
signature="org.objectweb.transaction.api.coordination.CoordinationFeature"/>
+  <interface name="abort" role="server"
+        
signature="org.objectweb.transaction.api.coordination.CoordinationFeature"/>
+  <interface name="subscribe" role="server"
+        signature="org.objectweb.transaction.api.event.SubscribeFeature"/>
+  <interface name="timeout-attr" role="server"
+        signature="org.objectweb.gotm.lib.coordination.TimeoutAttribute"/>
+  <interface name="synchronization" role="server"
+        signature="org.objectweb.gotm.lib.resource.ResourceManager"/>
+  <interface name="xa-resource" role="server"
+        signature="org.objectweb.gotm.lib.resource.ResourceManager"/>
+
+  <component name="TransactionState"
+       
definition="org.objectweb.gotm.lib.transaction.FcTransactionStateAuto"/>
+  <component name="CommitEngine"
+       definition="org.objectweb.gotm.lib.coordination.FcCommitEngine"/>
+  <component name="ResourceManager"
+       definition="org.objectweb.gotm.lib.FcResourceManager"/>
+  <component name="CommitProtocol"
+       definition="${protocol}"/>
+  <component name="CommunicationManager"
+       definition="${communication}"/>
+  <component name="XidFactory"
+       definition="org.objectweb.gotm.lib.jta.xa.FcXidProvider"/>
+
+  <binding client="this.tx-state"        server="TransactionState.tx-state"/>
+  <binding client="this.two-pc"          server="CommitEngine.commit"/>
+  <binding client="this.one-pc"          server="CommitEngine.commit-one"/>
+  <binding client="this.abort"           server="CommitEngine.abort"/>
+  <binding client="this.timeout-attr"    server="CommitEngine.timeout-attr"/>
+  <binding client="this.subscribe"       
server="CommunicationManager.subscribe"/>
+  <binding client="this.synchronization" 
server="ResourceManager.synchronization"/>
+  <binding client="this.xa-resource"     
server="ResourceManager.xa-resource"/>
+
+  <binding client="TransactionState.publish" 
server="CommunicationManager.sync-publish"/>
+
+  <binding client="CommitEngine.tx-state"          
server="TransactionState.tx-state"/>
+  <binding client="CommitEngine.timeout-subscribe" 
server="CommunicationManager.subscribe"/>
+  <binding client="CommitEngine.prepare-decision"  
server="CommitProtocol.prepare-decision"/>
+  <binding client="CommitEngine.commit-decision"   
server="CommitProtocol.commit-decision"/>
+  <binding client="CommitEngine.abort-decision"    
server="CommitProtocol.abort-decision"/>
+  <binding client="CommitEngine.init-log"          
server="CommitProtocol.init-log"/>
+  <binding client="CommitEngine.commit-log"        
server="CommitProtocol.commit-log"/>
+  <binding client="CommitEngine.abort-log"         
server="CommitProtocol.abort-log"/>
+  <binding client="CommitEngine.commit-end-log"    
server="CommitProtocol.commit-end-log"/>
+  <binding client="CommitEngine.abort-end-log"     
server="CommitProtocol.abort-end-log"/>
+  
+  <binding client="ResourceManager.tx-state"       
server="TransactionState.tx-state"/>
+  <binding client="ResourceManager.subscribe"      
server="CommunicationManager.subscribe"/>
+  <binding client="ResourceManager.xid-provider"   
server="XidFactory.xid-provider"/>
+  <binding client="ResourceManager.vote-log"       
server="CommitProtocol.vote-log"/>
+  <binding client="ResourceManager.commit-ack-log" 
server="CommitProtocol.commit-ack-log"/>
+  <binding client="ResourceManager.abort-ack-log"  
server="CommitProtocol.abort-ack-log"/>
+
+  <binding client="CommitProtocol.sync-publish"  
server="CommunicationManager.sync-publish"/>
+  <binding client="CommitProtocol.async-publish" 
server="CommunicationManager.async-publish"/>
+  <binding client="CommitProtocol.xid-provider" 
server="XidFactory.xid-provider"/>
+</definition>
Index: 
gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsAdaptiveTransactionManager.fractal
diff -u 
gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsAdaptiveTransactionManager.fractal:1.1
 
gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsAdaptiveTransactionManager.fractal:removed
--- 
gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsAdaptiveTransactionManager.fractal:1.1
       Mon Aug  8 15:30:05 2005
+++ 
gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsAdaptiveTransactionManager.fractal
   Fri Aug 12 14:31:27 2005
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="ISO-8859-1" ?>
-<!DOCTYPE definition PUBLIC 
-          "-//objectweb.org//DTD Fractal ADL 2.0//EN" 
-          "classpath://org/objectweb/fractal/adl/xml/standard.dtd">
-
-<definition name="org.objectweb.gotm.lib.JtsAdaptiveTransactionManager">
-  <interface name="transaction-manager" role="server"
-         signature="javax.transaction.TransactionManager"/>
-
-  <component name="FcMonitor"
-       definition="org.objectweb.gotm.lib.jta.FcTransactionManagerImpl"/>
-  <component name="FcCurrent"
-       
definition="org.objectweb.gotm.lib.context.FcConfigurableCurrentManager"/>
-  <component name="FcContext"
-       
definition="org.objectweb.gotm.lib.context.FcCommitProtocolAwareness"/>
-
-  <binding client="this.transaction-manager" 
-           server="FcMonitor.tx-manager"/>
-  <binding client="FcMonitor.current-manager"
-           server="FcCurrent.current-manager"/>
-  <binding client="FcCurrent.context-awareness"
-           server="FcContext.context-awareness"/>
-  <binding client="FcContext.configurable"
-           server="FcCurrent.configurable"/>
-</definition>
Index: gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsTransaction.fractal
diff -u 
gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsTransaction.fractal:1.3 
gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsTransaction.fractal:1.4
--- gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsTransaction.fractal:1.3    
  Mon Aug  8 15:30:05 2005
+++ gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsTransaction.fractal  Fri 
Aug 12 14:31:26 2005
@@ -13,26 +13,24 @@
   <interface name="subscribe" role="server"
         signature="org.objectweb.transaction.api.event.SubscribeFeature"/>
          
-  <component name="AdapterJTS"
-       definition="org.objectweb.gotm.lib.jta.TpTransactionImpl"/>
-  <component name="ConverterJTS"
-       definition="org.objectweb.gotm.lib.jta.TpStatusConverter"/>
+  <component name="JtsAdapter"
+       definition="org.objectweb.gotm.lib.jta.FcTransactionImpl"/>
+  <component name="JtsHelper"
+       definition="org.objectweb.gotm.lib.jta.FcStatusConverter"/>
   <component name="Transaction"
-       
definition="org.objectweb.gotm.lib.TpTransaction(${protocol},${communication})"/>
+       
definition="org.objectweb.gotm.lib.FcTransaction(${protocol},${communication})"/>
 
-  <binding client="this.transaction"      server="AdapterJTS.transaction"/>
-  <binding client="this.user-transaction" 
server="AdapterJTS.user-transaction"/>
-  <binding client="this.suspend-feature"  
server="AdapterJTS.suspend-feature"/>
+  <binding client="this.transaction"      server="JtsAdapter.transaction"/>
+  <binding client="this.user-transaction" 
server="JtsAdapter.user-transaction"/>
+  <binding client="this.suspend-feature"  
server="JtsAdapter.suspend-feature"/>
   <binding client="this.subscribe"        server="Transaction.subscribe"/>
   
-  <binding client="AdapterJTS.tx-state"         
server="Transaction.tx-state"/>
-  <binding client="AdapterJTS.commit-one"       server="Transaction.one-pc"/>
-  <binding client="AdapterJTS.commit"           server="Transaction.two-pc"/>
-  <binding client="AdapterJTS.rollback"         server="Transaction.abort"/>
-  <binding client="AdapterJTS.timeout-attr"     
server="Transaction.timeout-attr"/>
-  <binding client="AdapterJTS.synchronization"  
server="Transaction.synchronization"/>
-  <binding client="AdapterJTS.xa-resource"      
server="Transaction.xa-resource"/>
-  <binding client="AdapterJTS.status-converter" 
server="ConverterJTS.event-converter"/>
-
-  <template-controller desc="compositeTemplate" />
+  <binding client="JtsAdapter.tx-state"         
server="Transaction.tx-state"/>
+  <binding client="JtsAdapter.commit-one"       server="Transaction.one-pc"/>
+  <binding client="JtsAdapter.commit"           server="Transaction.two-pc"/>
+  <binding client="JtsAdapter.rollback"         server="Transaction.abort"/>
+  <binding client="JtsAdapter.timeout-attr"     
server="Transaction.timeout-attr"/>
+  <binding client="JtsAdapter.synchronization"  
server="Transaction.synchronization"/>
+  <binding client="JtsAdapter.xa-resource"      
server="Transaction.xa-resource"/>
+  <binding client="JtsAdapter.status-converter" 
server="JtsHelper.event-converter"/>
 </definition>
Index: 
gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsTransactionManager.fractal
diff -u 
gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsTransactionManager.fractal:1.2 
gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsTransactionManager.fractal:1.3
--- 
gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsTransactionManager.fractal:1.2 
      Mon Aug  8 15:30:05 2005
+++ gotm-jts/src/fractal/org/objectweb/gotm/lib/JtsTransactionManager.fractal 
  Fri Aug 12 14:31:26 2005
@@ -3,21 +3,25 @@
           "-//objectweb.org//DTD Fractal ADL 2.0//EN" 
           "classpath://org/objectweb/fractal/adl/xml/standard.dtd">
 
-<definition name="org.objectweb.gotm.lib.JtsTransactionManager" 
arguments="protocol,communication">
+<definition name="org.objectweb.gotm.lib.JtsTransactionManager" 
arguments="factory">
   <interface name="transaction-manager" role="server"
          signature="javax.transaction.TransactionManager"/>
+  <interface name="user-transaction" role="server"
+         signature="javax.transaction.UserTransaction"/>
 
   <component name="FcMonitor"
        definition="org.objectweb.gotm.lib.jta.FcTransactionManagerImpl"/>
   <component name="FcCurrent"
-       definition="org.objectweb.gotm.lib.FcStaticCurrentManager"/>
-  <component name="FcTemplate"
-       
definition="org.objectweb.gotm.lib.JtsTransaction(${protocol},${communication})"/>
+       definition="org.objectweb.gotm.lib.current.FcCurrentManagerImpl"/>
+  <component name="FcFactory"
+       definition="${factory}(org.objectweb.gotm.lib.JtsTransaction)"/>
 
-  <binding client="this.transaction-manager" 
-           server="FcMonitor.tx-manager"/>
-  <binding client="FcMonitor.current-manager"
-           server="FcCurrent.current-manager"/>
-  <binding client="FcCurrent.factory"
-           server="FcTemplate.component"/>
-</definition>
+    <binding client="this.transaction-manager" 
+             server="FcMonitor.transaction-manager"/>
+    <binding client="this.user-transaction" 
+             server="FcMonitor.user-transaction"/>
+    <binding client="FcMonitor.current-manager"
+             server="FcCurrent.current-manager"/>
+    <binding client="FcCurrent.transaction-factory"
+             server="FcFactory.transaction-factory"/>
+</definition>
\ No newline at end of file
Index: gotm-jts/src/fractal/org/objectweb/gotm/lib/TpResourceManager.fractal
diff -u 
gotm-jts/src/fractal/org/objectweb/gotm/lib/TpResourceManager.fractal:1.2 
gotm-jts/src/fractal/org/objectweb/gotm/lib/TpResourceManager.fractal:removed
--- gotm-jts/src/fractal/org/objectweb/gotm/lib/TpResourceManager.fractal:1.2 
  Mon Aug  8 15:30:05 2005
+++ gotm-jts/src/fractal/org/objectweb/gotm/lib/TpResourceManager.fractal     
  Fri Aug 12 14:31:27 2005
@@ -1,60 +0,0 @@
-<?xml version="1.0" encoding="ISO-8859-1" ?>
-<!DOCTYPE definition PUBLIC 
-          "-//objectweb.org//DTD Fractal ADL 2.0//EN" 
-          "classpath://org/objectweb/fractal/adl/xml/standard.dtd">
-
-<definition name="org.objectweb.gotm.lib.TpResourceManager" 
arguments="ResLog">
-  <interface name="synchronization" role="server"
-        signature="org.objectweb.gotm.lib.resource.ResourceManager"/>
-  <interface name="xa-resource" role="server"
-        signature="org.objectweb.gotm.lib.resource.ResourceManager"/>
-
-  <interface name="subscribe" role="client"
-        signature="org.objectweb.transaction.api.event.SubscribeFeature"/>
-  <interface name="tx-state" role="client"
-        
signature="org.objectweb.transaction.api.transaction.TransactionState"/>
-  <interface name="xid-provider" role="client"
-        signature="org.objectweb.gotm.lib.xid.XidFeature"/>
-  <interface name="vote-log" role="client"
-        signature="org.objectweb.transaction.api.logging.LoggerFeature"/>
-  <interface name="commit-ack-log" role="client"
-        signature="org.objectweb.transaction.api.logging.LoggerFeature"/>
-  <interface name="abort-ack-log" role="client"
-        signature="org.objectweb.transaction.api.logging.LoggerFeature"/>
-
-  <component name="FcSynchronizationManager" 
-       definition="org.objectweb.gotm.lib.resource.TpResourceManagerImpl"/>
-  <component name="FcSynchronizationActions"
-       
definition="org.objectweb.gotm.lib.jta.TpSynchronizationActionProvider"/>
-
-  <component name="FcXAResourceManager" 
-       definition="org.objectweb.gotm.lib.resource.TpResourceManagerImpl"/>
-  <component name="FcXAResourceActions"
-       
definition="org.objectweb.gotm.lib.jta.xa.TpXAResourceActionProvider"/>
-<!--
-  <component name="FcThread"
-       definition="org.objectweb.util.thread.comp.TpThreadManager(10,100)"/>
-  <binding client="FcSynchronizationManager.runnable-manager"
-           server="FcThread.runnable-manager"/>
-  <binding client="FcXAResourceManager.runnable-manager"
-           server="FcThread.runnable-manager"/>
--->
-
-  <binding client="this.synchronization" 
server="FcSynchronizationManager.resource"/>
-  <binding client="this.xa-resource"     
server="FcXAResourceManager.resource"/>
-
-  <binding client="FcSynchronizationManager.action-provider"
-           server="FcSynchronizationActions.action-provider"/>
-  <binding client="FcSynchronizationManager.subscribe" 
server="this.subscribe"/>
-  <binding client="FcSynchronizationManager.tx-state"  
server="this.tx-state"/>
-
-  <binding client="FcXAResourceManager.action-provider" 
server="FcXAResourceActions.action-provider"/>
-  <binding client="FcXAResourceManager.subscribe"       
server="this.subscribe"/>
-  <binding client="FcXAResourceManager.tx-state"        
server="this.tx-state"/>
-  <binding client="FcXAResourceActions.xid-provider"    
server="this.xid-provider"/>
-  <binding client="FcXAResourceActions.vote-log"        
server="this.vote-log"/>
-  <binding client="FcXAResourceActions.commit-ack-log"  
server="this.commit-ack-log"/>
-  <binding client="FcXAResourceActions.abort-ack-log"   
server="this.abort-ack-log"/>
-
-  <template-controller desc="compositeTemplate" />
-</definition>
Index: gotm-jts/src/fractal/org/objectweb/gotm/lib/TpTransaction.fractal
diff -u gotm-jts/src/fractal/org/objectweb/gotm/lib/TpTransaction.fractal:1.3 
gotm-jts/src/fractal/org/objectweb/gotm/lib/TpTransaction.fractal:removed
--- gotm-jts/src/fractal/org/objectweb/gotm/lib/TpTransaction.fractal:1.3     
  Mon Aug  8 15:30:05 2005
+++ gotm-jts/src/fractal/org/objectweb/gotm/lib/TpTransaction.fractal   Fri 
Aug 12 14:31:27 2005
@@ -1,77 +0,0 @@
-<?xml version="1.0" encoding="ISO-8859-1" ?>
-<!DOCTYPE definition PUBLIC 
-          "-//objectweb.org//DTD Fractal ADL 2.0//EN"
-          "classpath://org/objectweb/fractal/adl/xml/standard.dtd">
-
-<definition name="org.objectweb.gotm.lib.TpTransaction" 
arguments="protocol,communication">
-  <interface name="tx-state" role="server" 
-        
signature="org.objectweb.transaction.api.transaction.TransactionState"/>
-  <interface name="one-pc" role="server"
-        
signature="org.objectweb.transaction.api.coordination.CoordinationFeature"/>
-  <interface name="two-pc" role="server"
-        
signature="org.objectweb.transaction.api.coordination.CoordinationFeature"/>
-  <interface name="abort" role="server"
-        
signature="org.objectweb.transaction.api.coordination.CoordinationFeature"/>
-  <interface name="subscribe" role="server"
-        signature="org.objectweb.transaction.api.event.SubscribeFeature"/>
-  <interface name="timeout-attr" role="server"
-        signature="org.objectweb.gotm.lib.coordination.TimeoutAttribute"/>
-  <interface name="synchronization" role="server"
-        signature="org.objectweb.gotm.lib.resource.ResourceManager"/>
-  <interface name="xa-resource" role="server"
-        signature="org.objectweb.gotm.lib.resource.ResourceManager"/>
-
-  <component name="TransactionState"
-       
definition="org.objectweb.gotm.lib.transaction.TpTransactionStateAuto"/>
-  <component name="CommitEngine"
-       definition="org.objectweb.gotm.lib.coordination.TpCommitEngine"/>
-  <component name="ResourceManager"
-       definition="org.objectweb.gotm.lib.TpResourceManager"/>
-  <component name="CommitProtocol"
-       definition="${protocol}"/>
-  <component name="LogManager"
-       
definition="org.objectweb.gotm.lib.logging.TpLogManagerHOWL(log-${protocol},output)"/>
-  <component name="CommunicationManager"
-       definition="${communication}"/>
-  <component name="XidFactory"
-       definition="org.objectweb.gotm.lib.jta.xa.TpXidProvider"/>
-
-  <binding client="this.tx-state"        server="TransactionState.tx-state"/>
-  <binding client="this.two-pc"          server="CommitEngine.commit"/>
-  <binding client="this.one-pc"          server="CommitEngine.commit-one"/>
-  <binding client="this.abort"           server="CommitEngine.abort"/>
-  <binding client="this.timeout-attr"    server="CommitEngine.timeout-attr"/>
-  <binding client="this.subscribe"       
server="CommunicationManager.subscribe"/>
-  <binding client="this.synchronization" 
server="ResourceManager.synchronization"/>
-  <binding client="this.xa-resource"     
server="ResourceManager.xa-resource"/>
-
-  <binding client="TransactionState.publish" 
server="CommunicationManager.sync-publish"/>
-
-  <binding client="CommitEngine.tx-state"          
server="TransactionState.tx-state"/>
-  <binding client="CommitEngine.timeout-subscribe" 
server="CommunicationManager.subscribe"/>
-  <binding client="CommitEngine.prepare-decision"  
server="CommitProtocol.prepare-decision"/>
-  <binding client="CommitEngine.commit-decision"   
server="CommitProtocol.commit-decision"/>
-  <binding client="CommitEngine.abort-decision"    
server="CommitProtocol.abort-decision"/>
-  <binding client="CommitEngine.init-log"          
server="CommitProtocol.init-log"/>
-  <binding client="CommitEngine.commit-log"        
server="CommitProtocol.commit-log"/>
-  <binding client="CommitEngine.abort-log"         
server="CommitProtocol.abort-log"/>
-  <binding client="CommitEngine.commit-end-log"    
server="CommitProtocol.commit-end-log"/>
-  <binding client="CommitEngine.abort-end-log"     
server="CommitProtocol.abort-end-log"/>
-  
-  <binding client="ResourceManager.tx-state"       
server="TransactionState.tx-state"/>
-  <binding client="ResourceManager.subscribe"      
server="CommunicationManager.subscribe"/>
-  <binding client="ResourceManager.xid-provider"   
server="XidFactory.xid-provider"/>
-  <binding client="ResourceManager.vote-log"       
server="CommitProtocol.vote-log"/>
-  <binding client="ResourceManager.commit-ack-log" 
server="CommitProtocol.commit-ack-log"/>
-  <binding client="ResourceManager.abort-ack-log"  
server="CommitProtocol.abort-ack-log"/>
-
-  <binding client="CommitProtocol.sync-publish"  
server="CommunicationManager.sync-publish"/>
-  <binding client="CommitProtocol.async-publish" 
server="CommunicationManager.async-publish"/>
-  <binding client="CommitProtocol.force"         server="LogManager.force"/>
-  <binding client="CommitProtocol.no-force"      
server="LogManager.no-force"/>
-  <binding client="CommitProtocol.empty"         server="LogManager.empty"/>
-
-  <binding client="LogManager.xid-provider" 
server="XidFactory.xid-provider"/>
-
-  <template-controller desc="compositeTemplate"/>
-</definition>
Index: gotm-jts/src/java/org/objectweb/gotm/lib/JtsFactory.java
diff -u gotm-jts/src/java/org/objectweb/gotm/lib/JtsFactory.java:1.2 
gotm-jts/src/java/org/objectweb/gotm/lib/JtsFactory.java:1.3
--- gotm-jts/src/java/org/objectweb/gotm/lib/JtsFactory.java:1.2        Mon 
Aug  8 15:30:05 2005
+++ gotm-jts/src/java/org/objectweb/gotm/lib/JtsFactory.java    Fri Aug 12 
14:31:26 2005
@@ -23,7 +23,7 @@
 Contributor(s): .
 
 ---------------------------------------------------------------------
-$Id: JtsFactory.java,v 1.2 2005/08/08 13:30:05 rouvoy Exp $
+$Id: JtsFactory.java,v 1.3 2005/08/12 12:31:26 rouvoy Exp $
 ====================================================================*/
 package org.objectweb.gotm.lib;
 
@@ -32,13 +32,13 @@
 import javax.transaction.TransactionManager;
 
 import org.objectweb.fractal.api.Interface;
-import org.objectweb.gotm.Gotm;
+import org.objectweb.gotm.GotmFactory;
 
 /**
  * @author <a href="mailto:Romain.Rouvoy@xxxxxxx";>Romain Rouvoy</a>
  * @created 11 juil. 2005
- * @modified $Date: 2005/08/08 13:30:05 $
- * @version $Revision: 1.2 $
+ * @modified $Date: 2005/08/12 12:31:26 $
+ * @version $Revision: 1.3 $
  */
 public class JtsFactory {
     /** <code>DEFAULT_ADL</code> . */
@@ -60,7 +60,7 @@
      * @return an instance of transaction manager.
      */
     public static final TransactionManager create(String desc, Map context) {
-        return (TransactionManager)Gotm.create(desc, context, DEFAULT_ITF);
+        return (TransactionManager)GotmFactory.create(desc, context, 
DEFAULT_ITF);
     }
 
     /**
@@ -68,6 +68,6 @@
      * @param tm the transaction manager to stop.
      */
     public static final void stop(TransactionManager tm) {
-        Gotm.stop((Interface)tm);
+        GotmFactory.stop((Interface)tm);
     }
 }
Index: gotm-jts/src/java/org/objectweb/gotm/lib/jta/TransactionCurrent.java
diff -u /dev/null 
gotm-jts/src/java/org/objectweb/gotm/lib/jta/TransactionCurrent.java:1.1
--- /dev/null   Fri Aug 12 14:31:27 2005
+++ gotm-jts/src/java/org/objectweb/gotm/lib/jta/TransactionCurrent.java      
  Fri Aug 12 14:31:26 2005
@@ -0,0 +1,51 @@
+/*====================================================================
+
+ GoTM: GoTM is an open Transaction Monitor
+ Copyright (C) 2003-2005 INRIA - Jacquard & USTL - LIFL - GOAL
+ Contact: gotm-team@xxxxxxxxxxxxx
+
+ This library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or any later version.
+
+ This library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with this library; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307
+ USA
+
+ Initial developer(s): Romain Rouvoy.
+ Contributor(s): .
+
+ ---------------------------------------------------------------------
+ $Id: TransactionCurrent.java,v 1.1 2005/08/12 12:31:26 rouvoy Exp $
+ ====================================================================*/
+package org.objectweb.gotm.lib.jta;
+
+import java.io.Serializable;
+
+import javax.naming.Referenceable;
+import javax.transaction.TransactionManager;
+
+import org.objectweb.transaction.api.Feature;
+
+/**
+ * @author <a href="mailto:Romain.Rouvoy@xxxxxxx";>Romain Rouvoy</a>
+ * @created 9 août 2005
+ * @modified $Date: 2005/08/12 12:31:26 $
+ * @version $Revision: 1.1 $
+ * @fractal.itf
+ */
+public interface TransactionCurrent
+        extends Feature, Referenceable, Serializable {
+    /**
+     * @return the reference of the transaction manager to use.
+     */
+    TransactionManager getTransactionManager() ;
+    
+}
\ No newline at end of file
Index: 
gotm-jts/src/java/org/objectweb/gotm/lib/jta/TransactionManagerImpl.java
diff -u 
gotm-jts/src/java/org/objectweb/gotm/lib/jta/TransactionManagerImpl.java:1.6 
gotm-jts/src/java/org/objectweb/gotm/lib/jta/TransactionManagerImpl.java:1.7
--- 
gotm-jts/src/java/org/objectweb/gotm/lib/jta/TransactionManagerImpl.java:1.6  
      Mon Aug  8 15:30:05 2005
+++ gotm-jts/src/java/org/objectweb/gotm/lib/jta/TransactionManagerImpl.java  
  Fri Aug 12 14:31:26 2005
@@ -22,137 +22,49 @@
  Contributor(s): ______________________________________.
 
  ---------------------------------------------------------------------
- $Id: TransactionManagerImpl.java,v 1.6 2005/08/08 13:30:05 rouvoy Exp $
+ $Id: TransactionManagerImpl.java,v 1.7 2005/08/12 12:31:26 rouvoy Exp $
  ====================================================================*/
 
 package org.objectweb.gotm.lib.jta;
 
-import javax.transaction.HeuristicMixedException;
-import javax.transaction.HeuristicRollbackException;
-import javax.transaction.NotSupportedException;
-import javax.transaction.RollbackException;
-import javax.transaction.Status;
 import javax.transaction.SystemException;
 import javax.transaction.Transaction;
 import javax.transaction.TransactionManager;
-import javax.transaction.UserTransaction;
 
 import org.objectweb.fractal.api.Interface;
-import org.objectweb.fractal.api.NoSuchInterfaceException;
-import org.objectweb.fractal.lib.BindablePrimitive;
-import org.objectweb.gotm.lib.CurrentManager;
 
 /**
- * Implementation of the <code>javax.transaction.TransactionManager</code> 
+ * Implementation of the <code>javax.transaction.TransactionManager</code>
  * interface based on the GoTM library.
+ * 
  * @author <a href="mailto:Romain.Rouvoy@xxxxxxx";>Romain Rouvoy</a>
  * @created 3 janv. 2005
- * @modified $Date: 2005/08/08 13:30:05 $
- * @version $Revision: 1.6 $
- * @fractal.itf name="tx-manager" 
signature="javax.transaction.TransactionManager"
- * @fractal.itf name="current-manager" role="client" 
signature="org.objectweb.gotm.lib.CurrentManager"
+ * @modified $Date: 2005/08/12 12:31:26 $
+ * @version $Revision: 1.7 $
+ * @fractal.itf name="transaction-manager"
+ *              signature="javax.transaction.TransactionManager"
  */
 public class TransactionManagerImpl
-extends BindablePrimitive
+        extends UserTransactionImpl
         implements TransactionManager {
 
-    /** The default timeout. */
-    private int txTimeout = 0;
-
-    /**
-     * @return Returns the txTimeout.
-     */
-    protected int getTxTimeout() {
-        return this.txTimeout;
-    }
-
     /**
-     * @param txTimeout The txTimeout to set.
-     */
-    protected void setTxTimeout(int txTimeout) {
-        this.txTimeout = txTimeout;
-    }
-
-    /* (non-Javadoc)
-     * @see org.objectweb.fractal.lib.BindablePrimitive#clientFc()
-     */
-    protected String[] clientFc() {
-        return new String[]{CurrentManager.CURRENT_MANAGER};
-    }
-    
-    /**
-     * @return the instance of current manager associated to the current 
transaction manager
-     */
-    protected CurrentManager manager() {
-        return (CurrentManager) 
fcBindings.get(CurrentManager.CURRENT_MANAGER);
-    }
-    
-    /**
-     * @return Returns the currentTx.
+     * @return Returns the suspend feature of the transaction.
      * @throws SystemException
-     * @throws NotSupportedException
      */
-    protected final UserTransaction getCurrentUserTx() throws 
SystemException,
-            NotSupportedException {
+    protected final Suspendable getTxSuspendable() throws SystemException {
         try {
-            return (UserTransaction) manager().getCurrentFc().getFcInterface(
-                    "user-transaction");
-        } catch (NoSuchInterfaceException e) {
-            throw new NotSupportedException(e.getClass() + ": "
-                    + e.getMessage());
-        } catch (NullPointerException e) {
-            throw new SystemException("No current transaction");
-        }
-    }
-
-    /**
-     * @return Returns the currentTx.
-     * @throws SystemException this exception is thrown if no current 
-     * transaction is available.
-     */
-    protected final Transaction getCurrentTx() throws SystemException {
-        try {
-            return (Transaction) 
manager().getCurrentFc().getFcInterface("transaction");
+            return (Suspendable) manager().getCurrent().getFcInterface(
+                    Suspendable.SUSPENDABLE);
         } catch (Exception e) {
-            throw new SystemException("No current transaction");
+            throw new SystemException(
+                    "Transaction can not be suspended/resumed");
         }
     }
 
-    /**
-     * @return Returns the suspend feature of the transaction. 
-     * @throws SystemException
-     */
-    protected final Suspendable getTxSuspendable() throws SystemException{
-        try {
-            return (Suspendable) 
manager().getCurrentFc().getFcInterface(Suspendable.SUSPENDABLE);
-        } catch (Exception e) {
-            throw new SystemException("Transaction can not be 
suspended/resumed");
-        }
-    }
-    
-    /* (non-Javadoc)
-     * @see javax.transaction.TransactionManager#begin()
-     */
-    public void begin() throws NotSupportedException, SystemException {
-        if (manager().checkCurrent())
-            throw new NotSupportedException("A transaction is still 
active.");
-        manager().loadCurrent();
-        getCurrentUserTx().setTransactionTimeout(getTxTimeout());
-        getCurrentUserTx().begin();
-    }
-
-    /* (non-Javadoc)
-     * @see javax.transaction.TransactionManager#getStatus()
-     */
-    public int getStatus() {
-        try {
-            return getCurrentTx().getStatus();
-        } catch (Exception e) {
-            return Status.STATUS_NO_TRANSACTION;
-        }
-    }
-
-    /* (non-Javadoc)
+    /*
+     * (non-Javadoc)
+     * 
      * @see javax.transaction.TransactionManager#getTransaction()
      */
     public Transaction getTransaction() throws SystemException {
@@ -172,55 +84,20 @@
             return null;
         }
         getTxSuspendable().suspend();
-        manager().setCurrentFc(null);
+        manager().setCurrent(null);
         return tx;
     }
 
-    /* (non-Javadoc)
+    /*
+     * (non-Javadoc)
+     * 
      * @see 
javax.transaction.TransactionManager#resume(javax.transaction.Transaction)
      */
     public void resume(Transaction arg0) throws SystemException {
         if (manager().checkCurrent())
-            throw new IllegalStateException("A transaction is currently 
active.");
-        manager().setCurrentFc(((Interface) arg0).getFcItfOwner());
+            throw new IllegalStateException(
+                    "A transaction is currently active.");
+        manager().setCurrent(((Interface) arg0).getFcItfOwner());
         getTxSuspendable().resume();
     }
-
-    /* (non-Javadoc)
-     * @see javax.transaction.TransactionManager#setTransactionTimeout(int)
-     */
-    public void setTransactionTimeout(int arg0) {
-        setTxTimeout(arg0);
-    }
-
-    /* (non-Javadoc)
-     * @see javax.transaction.TransactionManager#setRollbackOnly()
-     */
-    public void setRollbackOnly() throws IllegalStateException, 
SystemException {
-        getCurrentTx().setRollbackOnly();
-    }
-
-    /* (non-Javadoc)
-     * @see javax.transaction.TransactionManager#rollback()
-     */
-    public void rollback() throws IllegalStateException, SecurityException,
-            SystemException {
-        getCurrentTx().rollback();
-        manager().clearCurrentFc();
-    }
-
-    /* (non-Javadoc)
-     * @see javax.transaction.TransactionManager#commit()
-     */
-    public void commit() throws RollbackException, HeuristicMixedException,
-            HeuristicRollbackException, SecurityException,
-            IllegalStateException, SystemException {
-        try {
-            getCurrentTx().commit();
-        } catch (IllegalStateException e) {
-            throw new RollbackException(e.getMessage());
-        } finally {
-            manager().clearCurrentFc();
-        }
-    }
 }
\ No newline at end of file
Index: gotm-jts/src/java/org/objectweb/gotm/lib/jta/UserTransactionImpl.java
diff -u /dev/null 
gotm-jts/src/java/org/objectweb/gotm/lib/jta/UserTransactionImpl.java:1.1
--- /dev/null   Fri Aug 12 14:31:27 2005
+++ gotm-jts/src/java/org/objectweb/gotm/lib/jta/UserTransactionImpl.java     
  Fri Aug 12 14:31:26 2005
@@ -0,0 +1,195 @@
+/*====================================================================
+
+GoTM: GoTM is an open Transaction Monitor
+Copyright (C) 2003-2005 INRIA - Jacquard & USTL - LIFL - GOAL
+Contact: gotm-team@xxxxxxxxxxxxx
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of the GNU Lesser General Public
+License as published by the Free Software Foundation; either
+version 2.1 of the License, or any later version.
+
+This library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this library; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307
+USA
+
+Initial developer(s): Romain Rouvoy.
+Contributor(s): .
+
+---------------------------------------------------------------------
+$Id: UserTransactionImpl.java,v 1.1 2005/08/12 12:31:26 rouvoy Exp $
+====================================================================*/
+package org.objectweb.gotm.lib.jta;
+
+import javax.transaction.HeuristicMixedException;
+import javax.transaction.HeuristicRollbackException;
+import javax.transaction.NotSupportedException;
+import javax.transaction.RollbackException;
+import javax.transaction.Status;
+import javax.transaction.SystemException;
+import javax.transaction.Transaction;
+import javax.transaction.UserTransaction;
+
+import org.objectweb.fractal.api.NoSuchInterfaceException;
+import org.objectweb.fractal.lib.BindablePrimitive;
+import org.objectweb.gotm.lib.current.CurrentManager;
+
+/**
+ * Implementation of a current user transaction.
+ * @author <a href="mailto:Romain.Rouvoy@xxxxxxx";>Romain Rouvoy</a>
+ * @created 9 août 2005
+ * @modified $Date: 2005/08/12 12:31:26 $
+ * @version $Revision: 1.1 $
+ * @fractal.itf name="user-transaction"
+ *              signature="javax.transaction.UserTransaction"
+ * @fractal.itf name="current-manager" role="client"
+ *              signature="org.objectweb.gotm.lib.current.CurrentManager"
+ */
+public class UserTransactionImpl
+        extends BindablePrimitive
+        implements UserTransaction {
+
+    /** <code>DEFAULT_TIMEOUT</code> value. */
+    public static final Integer DEFAULT_TIMEOUT = new Integer(60);
+    Integer default_timeout = DEFAULT_TIMEOUT;
+    /** The default timeout. */
+    private final ThreadLocal txTimeout = new ThreadLocal() {
+        protected synchronized Object initialValue() {
+            return default_timeout ;
+        }
+    };
+
+    /**
+     * @return Returns the txTimeout.
+     */
+    protected int getTxTimeout() {
+        return ((Integer) txTimeout.get()).intValue();
+    }
+
+    /**
+     * @param timeout
+     *            The txTimeout to set.
+     */
+    protected void setTxTimeout(int timeout) {
+        txTimeout.set(new Integer(timeout));
+    }
+
+    /* (non-Javadoc)
+     * @see org.objectweb.fractal.lib.BindablePrimitive#clientFc()
+     */
+    protected String[] clientFc() {
+        return new String[] { CurrentManager.CURRENT_MANAGER };
+    }
+
+    /**
+     * @return the instance of current manager associated to the current
+     *         transaction manager
+     */
+    protected CurrentManager manager() {
+        return (CurrentManager) 
fcBindings.get(CurrentManager.CURRENT_MANAGER);
+    }
+
+    /**
+     * @return Returns the currentTx.
+     * @throws SystemException
+     * @throws NotSupportedException
+     */
+    protected final UserTransaction getCurrentUserTx() throws 
SystemException,
+            NotSupportedException {
+        try {
+            return (UserTransaction) manager().getCurrent().getFcInterface(
+                    "user-transaction");
+        } catch (NoSuchInterfaceException e) {
+            throw new NotSupportedException(e.getClass() + ": "
+                    + e.getMessage());
+        } catch (NullPointerException e) {
+            throw new SystemException("No current transaction");
+        }
+    }
+
+    /**
+     * @return Returns the currentTx.
+     * @throws SystemException
+     *             this exception is thrown if no current transaction is
+     *             available.
+     */
+    protected final Transaction getCurrentTx() throws SystemException {
+        try {
+            return (Transaction) manager().getCurrent().getFcInterface(
+                    "transaction");
+        } catch (Exception e) {
+            throw new SystemException("No current transaction");
+        }
+    }
+
+    /* (non-Javadoc)
+     * @see javax.transaction.UserTransaction#begin()
+     */
+    public void begin() throws NotSupportedException, SystemException {
+        if (manager().checkCurrent())
+            throw new NotSupportedException("A transaction is still 
active.");
+        manager().loadCurrent();
+        getCurrentUserTx().setTransactionTimeout(getTxTimeout());
+        getCurrentUserTx().begin();
+    }
+
+    /* (non-Javadoc)
+     * @see javax.transaction.UserTransaction#getStatus()
+     */
+    public int getStatus() {
+        try {
+            return getCurrentTx().getStatus();
+        } catch (Exception e) {
+            return Status.STATUS_NO_TRANSACTION;
+        }
+    }
+    
+    /*
+     * (non-Javadoc)
+     * 
+     * @see javax.transaction.TransactionManager#setTransactionTimeout(int)
+     */
+    /* (non-Javadoc)
+     * @see javax.transaction.UserTransaction#setTransactionTimeout(int)
+     */
+    public void setTransactionTimeout(int arg0) {
+        setTxTimeout(arg0);
+    }
+
+    /* (non-Javadoc)
+     * @see javax.transaction.UserTransaction#setRollbackOnly()
+     */
+    public void setRollbackOnly() throws IllegalStateException, 
SystemException {
+        getCurrentTx().setRollbackOnly();
+    }
+
+    /* (non-Javadoc)
+     * @see javax.transaction.UserTransaction#rollback()
+     */
+    public void rollback() throws IllegalStateException, SecurityException,
+            SystemException {
+        getCurrentTx().rollback();
+        manager().clearCurrent();
+    }
+
+    /* (non-Javadoc)
+     * @see javax.transaction.UserTransaction#commit()
+     */
+    public void commit() throws RollbackException, HeuristicMixedException,
+            HeuristicRollbackException, SecurityException,
+            IllegalStateException, SystemException {
+        try {
+            getCurrentTx().commit();
+        } catch (IllegalStateException e) {
+            throw new RollbackException(e.getMessage());
+        } finally {
+            manager().clearCurrent();
+        }
+    }
+}
\ No newline at end of file



<--  Date Index  --> <--  Thread Index  -->

Reply via email to:

Powered by MHonArc.

Copyright © 2006-2007, OW2 Consortium | contact | webmaster.