Package com.arjuna.ats.arjuna

Examples of com.arjuna.ats.arjuna.AtomicAction.abort()


                System.out.println("About to complete the transaction ");
                // Try to complete the transaction as requested by the user
                if (commit)
                    actionStatus = tx.commit()// Top level commit
                else
                    actionStatus = tx.abort()// Top level rollback

                System.out.println("The status of the transaction is " + ActionStatus.stringForm(actionStatus));
            }
            else
            {
View Full Code Here


      B.begin();

      bo.destroy();

      B.abort();

      AtomicAction C = new AtomicAction();

      C.begin();
View Full Code Here

  for (int i = 0; i < numberOfTransactions; i++)
  {
      AtomicAction A = new AtomicAction();

      A.begin();
      A.abort();
  }

  long ftime = Calendar.getInstance().getTime().getTime();
  long timeTaken = ftime - stime;
View Full Code Here

        {
          mLockRecordList[j].increase();
        }
      }
      //abort transaction
      b.abort();
    }
    catch (Exception e)
    {
      mCorrect = false;
      qautil.debug("exception in worker001: ", e);
View Full Code Here

        {
          mLockRecordList[j].increase();
        }
      }
      //abort transaction
      b.abort();
    }
    catch (Exception e)
    {
      mCorrect = false;
      qautil.debug("exception in worker001: ", e);
View Full Code Here

            a.commit();
            expectedValue[j] += incValue;
          }
          else
          {
            a.abort();
          }
        }
      }

      for (int j = 0; j < mNumberOfResources; j++)
View Full Code Here

            b.commit();
            expectedValue[j] += incValue;
          }
          else
          {
            b.abort();
          }
        }
      }
    }
    catch (Exception e)
View Full Code Here

      //start new AtomicAction
      AtomicAction b = new AtomicAction();
      b.begin();
      mService.setupOper(true);
      mService.doWork(mMaxIteration);
      b.abort();
    }
    catch (Exception e)
    {
      mCorrect = false;
      qautil.debug("exception in worker002: ", e);
View Full Code Here

      //start new AtomicAction
      AtomicAction b = new AtomicAction();
      b.begin();
      mService.setupOper();
      mService.doWork(mMaxIteration);
      b.abort();
    }
    catch (Exception e)
    {
      mCorrect = false;
      qautil.debug("exception in worker001: ", e);
View Full Code Here

      while ((locking_result != LockResult.GRANTED) && (locking_attempt_count < mLimit));

      if (locking_result != LockResult.GRANTED)
      {
        qautil.qadebug("trying to get lock for " + mLimit + "th time");
        a.abort();
      }
      else
      {
        a.commit();
        returnValue = 1;
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.