/** {@inheritDoc} */ @Override public final void addActiveCache(GridCacheContext cacheCtx, boolean recovery) throws IgniteCheckedException { txState.addActiveCache(cacheCtx, recovery, this); }
/** {@inheritDoc} */ @Override public Collection<IgniteTxEntry> allEntries() { return txState.allEntries(); }
/** * Resume transaction if it was previously suspended. * * @param tx Transaction to resume. * @throws IgniteCheckedException If resume failed. */ public void resumeTx(GridNearTxLocal tx) throws IgniteCheckedException { tx.txState().awaitLastFuture(this); tx.resume(); }
/** * @param tx Transaction to commit. * @return Commit future. */ @SuppressWarnings("unchecked") public IgniteInternalFuture<IgniteInternalTx> commitTxAsync(GridNearTxLocal tx) { GridCacheContext ctx = tx.txState().singleCacheContext(this); if (ctx == null) { tx.txState().awaitLastFuture(this); return tx.commitNearTxLocalAsync(); } else return ctx.cache().commitTxAsync(tx); }
if (!tx0.txState().implicitSingle()) tx0.txState().awaitLastFuture(ctx.shared());
txEntry.expiry(expiryPlc); txState.addEntry(txEntry);
/** * @return {@code True} if transaction participates in a cache that has an interceptor configured. */ public boolean hasInterceptor() { return txState().hasInterceptor(cctx); }
/** {@inheritDoc} */ @Nullable @Override public IgniteTxEntry entry(IgniteTxKey key) { return txState.entry(key); }
/** {@inheritDoc} */ @Override public boolean hasWriteKey(IgniteTxKey key) { return txState.hasWriteKey(key); }
/** {@inheritDoc} */ @Override public boolean empty() { return txState.empty(); }
/** * @param tx Transaction to commit. * @return Commit future. */ @SuppressWarnings("unchecked") public IgniteInternalFuture<IgniteInternalTx> commitTxAsync(GridNearTxLocal tx) { GridCacheContext ctx = tx.txState().singleCacheContext(this); if (ctx == null) { tx.txState().awaitLastFuture(this); return tx.commitNearTxLocalAsync(); } else return ctx.cache().commitTxAsync(tx); }
if (!tx0.txState().implicitSingle()) tx0.txState().awaitLastFuture(ctx.shared());
txState.addEntry(existing);
/** * @return {@code True} if transaction participates in a cache that has an interceptor configured. */ public boolean hasInterceptor() { return txState().hasInterceptor(cctx); }
/** {@inheritDoc} */ @Nullable @Override public IgniteTxEntry entry(IgniteTxKey key) { return txState.entry(key); }
/** {@inheritDoc} */ @Override public boolean hasWriteKey(IgniteTxKey key) { return txState.hasWriteKey(key); }
/** {@inheritDoc} */ @Override public boolean empty() { return txState.empty(); }
/** * Suspends transaction. It could be resume later. Supported only for optimistic transactions. * * @param tx Transaction to suspend. * @throws IgniteCheckedException If suspension failed. */ public void suspendTx(GridNearTxLocal tx) throws IgniteCheckedException { tx.txState().awaitLastFuture(this); tx.suspend(); }