@Override
  public TransactionListener setListener(TransactionListener newListener) {
    synchronized (txListeners) {
      TransactionListener result = getListener();
      txListeners.clear();
      if (newListener != null) {
        txListeners.add(newListener);
      }
      if (result != null) {
        closeListener(result);
      }
      return result;
    }
  }
Get the TransactionWriter for the cache

@return the current TransactionWriter
@see TransactionWriter
geode-core/src/main/java/org/apache/geode/internal/cache/TXManagerImpl.java