Examples of TxContext


Examples of com.arjuna.mw.wst.TxContext

  }
    }

    public final void tidyup ()
    {
  TxContext txCtx = (TxContext) _threadTxData.get();
 
  if (txCtx != null)
  {
      _threadTxData.set(null) ;
      _contextMapper.remove(txCtx);
View Full Code Here

Examples of com.arjuna.mw.wst.TxContext

    public static TxContext importContext(CoordinationContextType cc)
    {
        // get the subordinate transaction manager to install any existing
        // subordinate tx for this one or create and install a new one.
        final String identifier = cc.getIdentifier().getValue();
        TxContext subordinateTxContext = subordinateContextMap.get(identifier);
        if (subordinateTxContext == null) {
            // create a context for a local coordinator
            CoordinationContextType context = null;
            try {
                context = atContextFactory.create(AtomicTransactionConstants.WSAT_PROTOCOL, 0L, cc);
View Full Code Here

Examples of com.arjuna.mw.wst.TxContext

                    final CoordinationContextType cc = CoordinationContextHelper.deserialise(soapHeaderElement) ;
                    final String coordinationType = cc.getCoordinationType();
                    if (AtomicTransactionConstants.WSAT_PROTOCOL.equals(coordinationType))
                    {
                        clearMustUnderstand(soapHeader, soapHeaderElement) ;
                        TxContext txContext = new TxContextImple(cc) ;
                        if (installSubordinateTx) {
                            txContext = SubordinateImporter.importContext(cc);
                        }
                        TransactionManagerFactory.transactionManager().resume(txContext);
                    }
                    else if (BusinessActivityConstants.WSBA_PROTOCOL_ATOMIC_OUTCOME.equals(coordinationType))
                    {
                        // interposition is not yet implemented for business activities
                        clearMustUnderstand(soapHeader, soapHeaderElement) ;
                        if (installSubordinateTx) {
                            // throw an exception to force logging of a warning below
                            throw new Exception("com.arjuna.mw.wst11.service.JaxBaseHeaderContextProcessor : interposition is not yet implemented for the WSBA protocol");
                        }
                        final TxContext txContext = new com.arjuna.mwlabs.wst11.ba.context.TxContextImple(cc);
                        BusinessActivityManagerFactory.businessActivityManager().resume(txContext) ;
                    }
                    else
                    {
                        wstxLogger.arjLoggerI18N.warn("com.arjuna.mw.wst11.service.JaxHC11P_1",
View Full Code Here

Examples of com.arjuna.mw.wst.TxContext

    public void beginSubordinate(final int timeout)
        throws WrongStateException, SystemException
    {
        try
        {
            TxContext current = _ctxManager.currentTransaction();
            if (current == null || !(current instanceof TxContextImple))
                throw new WrongStateException();
            TxContextImple currentImple = (TxContextImple)current;
            com.arjuna.mw.wsc.context.Context ctx = startTransaction(timeout, currentImple);
View Full Code Here

Examples of com.arjuna.mw.wst.TxContext

  catch (com.arjuna.mw.wsas.exceptions.SystemException ex)
  {
      throw new SystemException(ex.toString());
  }

  TxContext txCtx = (TxContext) _threadTxData.get();
  if (txCtx != null)
  {
      _threadTxData.set(null) ;
  }
 
View Full Code Here

Examples of com.arjuna.mw.wst.TxContext

  }
    }

    public final void tidyup ()
    {
  TxContext txCtx = (TxContext) _threadTxData.get();
 
  if (txCtx != null)
  {
      _threadTxData.set(null) ;
      _contextMapper.remove(txCtx);
View Full Code Here

Examples of com.arjuna.mw.wst.TxContext

                    if (cc != null)
                    {
                        final String coordinationType = cc.getCoordinationType().getValue() ;
                        if (AtomicTransactionConstants.WSAT_PROTOCOL.equals(coordinationType))
                        {
                            final TxContext txContext = new com.arjuna.mwlabs.wst.at.context.TxContextImple(cc) ;
                            TransactionManagerFactory.transactionManager().resume(txContext) ;
                        }
                        else if (BusinessActivityConstants.WSBA_PROTOCOL_ATOMIC_OUTCOME.equals(coordinationType))
                        {
                            final TxContext txContext = new com.arjuna.mwlabs.wst.ba.context.TxContextImple(cc);
                            BusinessActivityManagerFactory.businessActivityManager().resume(txContext) ;
                        }
                        else
                        {
                      wstxLogger.arjLoggerI18N.warn("com.arjuna.mw.wst.client.JaxHCP_1",
View Full Code Here

Examples of com.arjuna.mw.wst.TxContext

    _threadTxData.set(tx);
  }

  public TxContext suspend () throws SystemException
  {
    final TxContext ctx = currentTransaction();
   
    if (ctx != null)
    {
      _threadTxData.set(null);
    }
View Full Code Here

Examples of com.arjuna.mw.wst.TxContext

        _threadTxData.set(tx);
    }
   
    public TxContext suspend () throws SystemException
    {
        final TxContext ctx = currentTransaction() ;
        if (ctx != null)
        {
            _threadTxData.set(null) ;
        }
  return ctx;
View Full Code Here

Examples of com.arjuna.mw.wst.TxContext

        final DemoVolatileParticipant p2 = new DemoVolatileParticipant();
        final FailureParticipant p3 = new FailureParticipant(FailureParticipant.FAIL_IN_PREPARE, FailureParticipant.WRONG_STATE);
        final DemoVolatileParticipant p4 = new DemoVolatileParticipant();

        ut.begin();
        final TxContext tx = tm.suspend();
        tm.resume(tx);
        tm.enlistForDurableTwoPhase(p1, p1.identifier());
        tm.enlistForVolatileTwoPhase(p2, p2.identifier());
        ust.begin();
        final TxContext stx = tm.suspend();
        tm.resume(stx);
        tm.enlistForDurableTwoPhase(p3, "failure in prepare");
        tm.enlistForVolatileTwoPhase(p4, p4.identifier());

        tm.resume(tx);
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.