public void removeOldVersions() {
    synchronized (memberToVersion) {
      long currentVersion = getCurrentVersion();
      for (Map.Entry<T, RegionVersionHolder<T>> entry : memberToVersion.entrySet()) {
        RegionVersionHolder<T> holder = entry.getValue();
        T id = entry.getKey();
        holder.removeExceptionsOlderThan(holder.version);
        memberToGCVersion.put(id, holder.version);
      }
      localGCVersion.set(getCurrentVersion());
      if (localExceptions != null) {
        synchronized (localExceptions) {
          localExceptions.removeExceptionsOlderThan(currentVersion);
        }
      }
    }
  }
This is used by clear() while version generation is locked to remove old exceptions and update
the GC vector to be the same as the current version vector
geode-core/src/main/java/org/apache/geode/internal/cache/versions/RegionVersionVector.java