Examples of UID


Examples of bitronix.tm.utils.Uid

        Set freshlyRecoveredXids = new HashSet();
        for (int i = 0; i < xids.length; i++) {
            Xid xid = xids[i];
            if (xid.getFormatId() != BitronixXid.FORMAT_ID) {
                if (log.isDebugEnabled()) log.debug("skipping non-bitronix XID " + xid + "(format ID: " + xid.getFormatId() +
                     " GTRID: " + new Uid(xid.getGlobalTransactionId()) + "BQUAL: " + new Uid(xid.getBranchQualifier()) + ")");
                continue;
             }

            BitronixXid bitronixXid = new BitronixXid(xid);
View Full Code Here

Examples of com.arjuna.ats.arjuna.common.Uid

         XAResource res1 = sess1.getXAResource();
  
         XAResource res2 = sess2.getXAResource();
  
         //Pretend to be a transaction manager by interacting through the XAResources
         Xid xid1 = new XidImple(new Uid("cadaver"), new Uid("bq1"), 666);
         Xid xid2 = new XidImple(new Uid("dalidom"), new Uid("bq2"), 661);   // TODO
  
  
         //    Send a message in each tx
  
         res1.start(xid1, XAResource.TMNOFLAGS);
View Full Code Here

Examples of com.arjuna.ats.arjuna.common.Uid

                  InputObjectState uids = new InputObjectState();

                  if (store.allObjUids(theName, uids))
                  {

                      Uid theUid;

                      try
                      {
                          boolean endOfUids = false;

                          while (!endOfUids)
                          {
                              theUid = UidHelper.unpackFrom(uids);

                              if (theUid.equals(Uid.nullUid()))
                                  endOfUids = true;
                              else
                                  ids.add(theUid);
                          }
                      }
View Full Code Here

Examples of com.arjuna.ats.arjuna.common.Uid

        Stack values = new Stack();
        boolean finished = false;
       
        do
        {
          Uid uid = new Uid(Uid.nullUid());

          try
          {
            uid.unpack(states);
          }
          catch (IOException ex)
          {
            ex.printStackTrace();

            finished = true;
          }

          if (uid.notEquals(Uid.nullUid()))
          {
            TransactionImple tx = TxImporter.recoverTransaction(uid);

            values.push(tx);
          }
View Full Code Here

Examples of com.arjuna.ats.arjuna.common.Uid

        Stack values = new Stack();
        boolean finished = false;
       
        do
        {
          Uid uid = new Uid(Uid.nullUid());

          try
          {
            uid.unpack(states);
          }
          catch (IOException ex)
          {
            ex.printStackTrace();

            finished = true;
          }
         
          if (uid.notEquals(Uid.nullUid()))
          {
            TransactionImple tx = TxImporter.recoverTransaction(uid);
           
            if (tx != null)
              values.push(tx);
View Full Code Here

Examples of com.arjuna.ats.arjuna.common.Uid

         XAResource res1 = sess1.getXAResource();

         XAResource res2 = sess2.getXAResource();

         // Pretend to be a transaction manager by interacting through the XAResources
         Xid xid1 = new XidImple(new Uid("cadaver"), new Uid("bq1"), 666);
         Xid xid2 = new XidImple(new Uid("dalidom"), new Uid("bq2"), 661); // TODO

         // Send a message in each tx

         res1.start(xid1, XAResource.TMNOFLAGS);
View Full Code Here

Examples of com.arjuna.ats.arjuna.common.Uid

            // enlist the Participant for this service:
            SetParticipantBA participant = new SetParticipantBA(value);
            BusinessActivityManager activityManager = BusinessActivityManagerFactory.businessActivityManager();
            log.info("[SERVICE] Enlisting a participant into the BA");
            participantManager = activityManager.enlistForBusinessAgreementWithParticipantCompletion(participant,
                    "SetServiceBAImpl:" + new Uid().toString());
        } catch (Exception e) {
            log.error("Participant enlistment failed");
            e.printStackTrace(System.err);
            throw new SetServiceException("Error enlisting participant", e);
        }
View Full Code Here

Examples of com.arjuna.ats.arjuna.common.Uid

                SetParticipantBA participant = new SetParticipantBA(transactionId, value);
                SetParticipantBA.recordParticipant(transactionId, participant);

                log.info("[SERVICE] Enlisting a participant into the BA");
                activityManager.enlistForBusinessAgreementWithCoordinatorCompletion(participant, "SetServiceBAImpl:"
                        + new Uid().toString());
            } catch (Exception e) {
                log.error("Participant enlistment failed");
                throw new SetServiceException("Error enlisting participant", e);
            }
        } else {
View Full Code Here

Examples of com.arjuna.ats.arjuna.common.Uid

            // enlist the Participant for this service:
            TransactionManager transactionManager = TransactionManagerFactory.transactionManager();
            RestaurantParticipant restaurantParticipant = new RestaurantParticipant(transactionId);
            log.info("[SERVICE] Enlisting a Durable2PC participant into the AT");
            transactionManager.enlistForDurableTwoPhase(restaurantParticipant, "restaurantServiceAT:" + new Uid().toString());

            RestaurantVolatileParticipant restaurantVolatileParticipant = new RestaurantVolatileParticipant(transactionId);
            log.info("[SERVICE] Enlisting a Volatile2PC participant into the AT");
            transactionManager.enlistForVolatileTwoPhase(restaurantVolatileParticipant, "restaurantServiceAT:" + new Uid().toString());

        } catch (Exception e) {
            throw new RestaurantException("Error when enlisting participants", e);
        }
View Full Code Here

Examples of com.arjuna.ats.arjuna.common.Uid

     * @param userTransactionID User transaction id
     * @return Returns the {@link Transaction} corresponding to the passed <code>userTransactionID</code>. If there
     *          is no such transaction, then this method returns null
     */
    public Transaction removeUserTransaction(final UserTransactionID userTransactionID) {
        final Uid uid = this.userTransactions.remove(userTransactionID);
        if (uid == null) {
            return null;
        }
        return TransactionImple.getTransaction(uid);
    }
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.