final LocalTransaction localTransaction = (LocalTransaction) transaction; final XAOutflowHandle outflowHandle = transactionContext.outflowTransaction(uri, localTransaction); final Xid xid = outflowHandle.getXid(); dataOutput.writeByte(2); dataOutput.writeInt(xid.getFormatId()); dataOutput.writeInt(bq.length); dataOutput.write(bq); dataOutput.writeInt(outflowHandle.getRemainingTime()); return outflowHandle; } else {
if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { try { outflowHandle.verifyEnlistment(); } catch (RollbackException | SystemException e1) { throw new EJBException(e1); outflowHandle.nonMasterEnlistment();
private TransactionID calculateTransactionId(final Transaction transaction) throws RollbackException, SystemException, InvalidTransactionException { final URI location = channel.getConnection().getPeerURI(); Assert.assertNotNull(transaction); if (transaction instanceof RemoteTransaction) { final RemoteTransaction remoteTransaction = (RemoteTransaction) transaction; remoteTransaction.setLocation(location); final SimpleIdResolver ir = remoteTransaction.getProviderInterface(SimpleIdResolver.class); if (ir == null) throw Logs.TXN.cannotEnlistTx(); return new UserTransactionID(channel.getConnection().getRemoteEndpointName(), ir.getTransactionId(channel.getConnection())); } else if (transaction instanceof LocalTransaction) { final LocalTransaction localTransaction = (LocalTransaction) transaction; final XAOutflowHandle outflowHandle = transactionContext.outflowTransaction(location, localTransaction); // always verify V1/2 outflows outflowHandle.verifyEnlistment(); return new XidTransactionID(outflowHandle.getXid()); } else { throw Logs.TXN.cannotEnlistTx(); } }
private TransactionID calculateTransactionId(final Transaction transaction) throws RollbackException, SystemException, InvalidTransactionException { final URI location = channel.getConnection().getPeerURI(); Assert.assertNotNull(transaction); if (transaction instanceof RemoteTransaction) { final RemoteTransaction remoteTransaction = (RemoteTransaction) transaction; remoteTransaction.setLocation(location); final SimpleIdResolver ir = remoteTransaction.getProviderInterface(SimpleIdResolver.class); if (ir == null) throw Logs.TXN.cannotEnlistTx(); return new UserTransactionID(channel.getConnection().getRemoteEndpointName(), ir.getTransactionId(channel.getConnection())); } else if (transaction instanceof LocalTransaction) { final LocalTransaction localTransaction = (LocalTransaction) transaction; final XAOutflowHandle outflowHandle = transactionContext.outflowTransaction(location, localTransaction); // always verify V1/2 outflows outflowHandle.verifyEnlistment(); return new XidTransactionID(outflowHandle.getXid()); } else { throw Logs.TXN.cannotEnlistTx(); } }
if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { try { outflowHandle.verifyEnlistment(); } catch (RollbackException | SystemException e1) { throw new EJBException(e1); outflowHandle.nonMasterEnlistment(); if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { try { outflowHandle.verifyEnlistment(); } catch (RollbackException | SystemException e1) { throw new EJBException(e1); outflowHandle.nonMasterEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment();
final LocalTransaction localTransaction = (LocalTransaction) transaction; final XAOutflowHandle outflowHandle = transactionContext.outflowTransaction(location, localTransaction); final Xid xid = outflowHandle.getXid(); dataOutput.writeByte(2); PackedInteger.writePackedInteger(dataOutput, xid.getFormatId()); int transactionTimeout = outflowHandle.getRemainingTime(); if(transactionTimeout == 0) throw Logs.TXN.outflowTransactionTimeoutElapsed(transaction); PackedInteger.writePackedInteger(dataOutput, transactionTimeout);
private TransactionID calculateTransactionId(final Transaction transaction) throws RollbackException, SystemException, InvalidTransactionException { final URI location = channel.getConnection().getPeerURI(); Assert.assertNotNull(transaction); if (transaction instanceof RemoteTransaction) { final RemoteTransaction remoteTransaction = (RemoteTransaction) transaction; remoteTransaction.setLocation(location); final SimpleIdResolver ir = remoteTransaction.getProviderInterface(SimpleIdResolver.class); if (ir == null) throw Logs.TXN.cannotEnlistTx(); return new UserTransactionID(channel.getConnection().getRemoteEndpointName(), ir.getTransactionId(channel.getConnection())); } else if (transaction instanceof LocalTransaction) { final LocalTransaction localTransaction = (LocalTransaction) transaction; final XAOutflowHandle outflowHandle = transactionContext.outflowTransaction(location, localTransaction); // always verify V1/2 outflows outflowHandle.verifyEnlistment(); return new XidTransactionID(outflowHandle.getXid()); } else { throw Logs.TXN.cannotEnlistTx(); } }
if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { outflowHandle.verifyEnlistment(); } else if (cmd == 2) { outflowHandle.nonMasterEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) {
final LocalTransaction localTransaction = (LocalTransaction) transaction; final XAOutflowHandle outflowHandle = transactionContext.outflowTransaction(uri, localTransaction); final Xid xid = outflowHandle.getXid(); dataOutput.writeByte(2); dataOutput.writeInt(xid.getFormatId()); dataOutput.writeInt(bq.length); dataOutput.write(bq); dataOutput.writeInt(outflowHandle.getRemainingTime()); return outflowHandle; } else {
if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { try { outflowHandle.verifyEnlistment(); } catch (RollbackException | SystemException e1) { throw new EJBException(e1); outflowHandle.nonMasterEnlistment();
final LocalTransaction localTransaction = (LocalTransaction) transaction; final XAOutflowHandle outflowHandle = transactionContext.outflowTransaction(uri, localTransaction); final Xid xid = outflowHandle.getXid(); dataOutput.writeByte(2); dataOutput.writeInt(xid.getFormatId()); dataOutput.writeInt(bq.length); dataOutput.write(bq); dataOutput.writeInt(outflowHandle.getRemainingTime()); return outflowHandle; } else {
if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { try { outflowHandle.verifyEnlistment(); } catch (RollbackException | SystemException e1) { throw new EJBException(e1); outflowHandle.nonMasterEnlistment();
final LocalTransaction localTransaction = (LocalTransaction) transaction; final XAOutflowHandle outflowHandle = transactionContext.outflowTransaction(location, localTransaction); final Xid xid = outflowHandle.getXid(); dataOutput.writeByte(2); PackedInteger.writePackedInteger(dataOutput, xid.getFormatId()); PackedInteger.writePackedInteger(dataOutput, outflowHandle.getRemainingTime()); return outflowHandle; } else {
if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { try { outflowHandle.verifyEnlistment(); } catch (RollbackException | SystemException e1) { throw new EJBException(e1); outflowHandle.nonMasterEnlistment(); if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { try { outflowHandle.verifyEnlistment(); } catch (RollbackException | SystemException e1) { throw new EJBException(e1); outflowHandle.nonMasterEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment();
final LocalTransaction localTransaction = (LocalTransaction) transaction; final XAOutflowHandle outflowHandle = transactionContext.outflowTransaction(location, localTransaction); final Xid xid = outflowHandle.getXid(); dataOutput.writeByte(2); PackedInteger.writePackedInteger(dataOutput, xid.getFormatId()); int transactionTimeout = outflowHandle.getRemainingTime(); if(transactionTimeout == 0) throw Logs.TXN.outflowTransactionTimeoutElapsed(transaction); PackedInteger.writePackedInteger(dataOutput, transactionTimeout);
if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { try { outflowHandle.verifyEnlistment(); } catch (RollbackException | SystemException e1) { throw new EJBException(e1); outflowHandle.nonMasterEnlistment(); if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { try { outflowHandle.verifyEnlistment(); } catch (RollbackException | SystemException e1) { throw new EJBException(e1); outflowHandle.nonMasterEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment();
if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { outflowHandle.verifyEnlistment(); } else if (cmd == 2) { outflowHandle.nonMasterEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) {
if (outflowHandle != null) { if (cmd == 0) { outflowHandle.forgetEnlistment(); } else if (cmd == 1) { outflowHandle.verifyEnlistment(); } else if (cmd == 2) { outflowHandle.nonMasterEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) { final XAOutflowHandle outflowHandle = getOutflowHandle(); if (outflowHandle != null) outflowHandle.forgetEnlistment(); if (version >= 3) {