public Map getExternalXids() { return new HashMap(recovery.getExternalXids()); }
public void recoverResourceManager(NamedXAResource xaResource) { try { recovery.recoverResourceManager(xaResource); } catch (XAException e) { recoveryError(e); } }
public TransactionManagerImpl(int defaultTransactionTimeoutSeconds, XidFactory xidFactory, TransactionLog transactionLog) throws XAException { if (defaultTransactionTimeoutSeconds <= 0) { throw new IllegalArgumentException("defaultTransactionTimeoutSeconds must be positive: attempted value: " + defaultTransactionTimeoutSeconds); } this.defaultTransactionTimeoutMilliseconds = defaultTransactionTimeoutSeconds * 1000; if (transactionLog == null) { this.transactionLog = new UnrecoverableLog(); } else { this.transactionLog = transactionLog; } if (xidFactory != null) { this.xidFactory = xidFactory; } else { this.xidFactory = new XidFactoryImpl(DEFAULT_TM_ID); } recovery = new RecoveryImpl(this); recovery.recoverLog(); }
public TransactionManagerImpl(int defaultTransactionTimeoutSeconds, XidFactory xidFactory, TransactionLog transactionLog) throws XAException { if (defaultTransactionTimeoutSeconds <= 0) { throw new IllegalArgumentException("defaultTransactionTimeoutSeconds must be positive: attempted value: " + defaultTransactionTimeoutSeconds); } this.defaultTransactionTimeoutMilliseconds = defaultTransactionTimeoutSeconds * 1000; if (transactionLog == null) { this.transactionLog = new UnrecoverableLog(); } else { this.transactionLog = transactionLog; } if (xidFactory != null) { this.xidFactory = xidFactory; } else { this.xidFactory = new XidFactoryImpl(DEFAULT_TM_ID); } recovery = new RecoveryImpl(this.transactionLog, this.xidFactory); recovery.recoverLog(); }
public void recoverResourceManager(NamedXAResource xaResource) { try { recovery.recoverResourceManager(xaResource); } catch (XAException e) { recoveryError(e); } }
public Map<Xid, TransactionImpl> getExternalXids() { return new HashMap<Xid, TransactionImpl>(recovery.getExternalXids()); }
public TransactionManagerImpl(int defaultTransactionTimeoutSeconds, XidFactory xidFactory, TransactionLog transactionLog) throws XAException { if (defaultTransactionTimeoutSeconds <= 0) { throw new IllegalArgumentException("defaultTransactionTimeoutSeconds must be positive: attempted value: " + defaultTransactionTimeoutSeconds); } this.defaultTransactionTimeoutMilliseconds = defaultTransactionTimeoutSeconds * 1000; if (transactionLog == null) { this.transactionLog = new UnrecoverableLog(); } else { this.transactionLog = transactionLog; } if (xidFactory != null) { this.xidFactory = xidFactory; } else { this.xidFactory = new XidFactoryImpl(DEFAULT_TM_ID); } recovery = new RecoveryImpl(this.transactionLog, this.xidFactory); recovery.recoverLog(); }
public void recoverResourceManager(NamedXAResource xaResource) { try { recovery.recoverResourceManager(xaResource); } catch (XAException e) { recoveryError(e); } }
public Map getExternalXids() { return new HashMap(recovery.getExternalXids()); }
public TransactionManagerImpl(int defaultTransactionTimeoutSeconds, XidFactory xidFactory, TransactionLog transactionLog) throws XAException { if (defaultTransactionTimeoutSeconds <= 0) { throw new IllegalArgumentException("defaultTransactionTimeoutSeconds must be positive: attempted value: " + defaultTransactionTimeoutSeconds); } this.defaultTransactionTimeoutMilliseconds = defaultTransactionTimeoutSeconds * 1000; if (transactionLog == null) { this.transactionLog = new UnrecoverableLog(); } else { this.transactionLog = transactionLog; } if (xidFactory != null) { this.xidFactory = xidFactory; } else { this.xidFactory = new XidFactoryImpl(DEFAULT_TM_ID); } recovery = new RecoveryImpl(this.transactionLog, this.xidFactory); recovery.recoverLog(); }
public void run() { try { NamedXAResource namedXAResource = namedXAResourceFactory.getNamedXAResource(); if (namedXAResource != null) { try { recovery.recoverResourceManager(namedXAResource); } finally { namedXAResourceFactory.returnNamedXAResource(namedXAResource); } } return; } catch (XAException e) { recoverableTransactionManager.recoveryError(e); } catch (SystemException e) { recoverableTransactionManager.recoveryError(e); } retryScheduler.retry(this, count++); } }
public Map getExternalXids() { return new HashMap(recovery.getExternalXids()); }