public TXStateProxy getTXState() {
    TXStateProxy tsp = txContext.get();
    if (tsp == PAUSED) {
      // treats paused transaction as no transaction.
      return null;
    }
    if (tsp != null && !tsp.isInProgress()) {
      txContext.set(null);
      tsp = null;
    }
    return tsp;
  }
Returns the TXStateProxyInterface of the current thread; null if no transaction.
geode-core/src/main/java/org/apache/geode/internal/cache/TXManagerImpl.java