public static void readyForEvents(InternalDistributedSystem system, boolean xmlPoolsOnly) {
    boolean foundDurablePool = false;
    Map<String, Pool> pools = PoolManager.getAll();
    for (Pool pool : pools.values()) {
      if (pool instanceof PoolImpl) {
        PoolImpl p = (PoolImpl) pool;
        if (p.isDurableClient()) {
          // TODO - handle an exception and attempt on all pools?
          foundDurablePool = true;
          if (!xmlPoolsOnly) {
            p.readyForEvents(system);
          }
        }
      }
    }
    if (pools.size() > 0 && !foundDurablePool) {
      throw new IllegalStateException(
          "Only durable clients should call readyForEvents()");
    }
  }
@param xmlPoolsOnly if true then only call readyForEvents on pools declared in XML.
geode-core/src/main/java/org/apache/geode/internal/cache/PoolManagerImpl.java