Package javax.transaction.xa

Examples of javax.transaction.xa.XAResource.prepare()


            ResultSet rs = s.executeQuery("select * from APP.foo");
            JDBCDisplayUtil.DisplayResults(System.out, rs, conn);
            rs.close();
            xar.end(xid3, XAResource.TMSUCCESS);

            int pr = xar.prepare(xid3);
            if (pr != XAResource.XA_RDONLY)
                System.out.println("FAIL - prepare on read only xact returned "
                        + pr);

            try {
View Full Code Here


                if (e.errorCode != XAException.XAER_NOTA)
                    throw e;
            }

            try {
                xar.prepare(xid11);
            } catch (XAException e) {
                if (e.errorCode != XAException.XAER_NOTA)
                    throw e;
            }
            try {
View Full Code Here

                    .executeQuery("select * from APP.foo where A >= 2000");
            JDBCDisplayUtil.DisplayResults(System.out, rs, conn);
            rs.close();

            xar.end(xid, XAResource.TMSUCCESS);
            xar.prepare(xid);

            /*
             -- dup id
             xa_start xa_noflags 1;
             */
 
View Full Code Here

            showHoldStatus("Global xact Statement psch_d ", psch_d);
            }
       
            xar.end(xid, XAResource.TMSUCCESS);
            if (xar.prepare(xid) != XAResource.XA_RDONLY)
                System.out.println("FAIL prepare didn't indicate r/o");
           
            // All the ResultSets should be closed. Run a simple
            // test, clearWarnings throws an error if the ResultSet
            // is closed.
View Full Code Here

        rsx.next(); System.out.println("X@3 id " + rsx.getInt(1));
      }
      xr.end(xid, XAResource.TMSUCCESS);


      if (xr.prepare(xid) != XAResource.XA_RDONLY)
        xr.commit(xid, false);

      // try again once the xa transaction has been committed.     
      try {
        rsx.next(); System.out.println("FAIL - rsx's connection not active id (B)" + rsx.getInt(1));
View Full Code Here

   public int prepare(Xid xid) throws XAException
   {
      XAResource xaResource = getDelegate();
      try
      {
         return xaResource.prepare(xid);
      }
      catch (XAException e)
      {
         throw check(e);
      }
View Full Code Here

           
            prod.send(tm);
           
            res.end(xid1, XAResource.TMSUCCESS);
           
            res.prepare(xid1);
        
         }
        
         {
           
View Full Code Here

           
            prod.send(tm);
           
            res.end(xid2, XAResource.TMSUCCESS);
           
            res.prepare(xid2);
        
         }
        
         List txList = (List)ServerManagement.invoke(ServerManagement.getServerPeerObjectName(),
                  "retrievePreparedTransactions", null, null);
View Full Code Here

           
            prod.send(tm);
           
            res.end(xid1, XAResource.TMSUCCESS);
           
            res.prepare(xid1);
        
         }
        
         {
           
View Full Code Here

           
            prod.send(tm);
           
            res.end(xid2, XAResource.TMSUCCESS);
           
            res.prepare(xid2);
        
         }
        
         String txList = (String)ServerManagement.invoke(ServerManagement.getServerPeerObjectName(),
                  "listAllPreparedTransactions", null, null);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.