private void clearLocalCache() {
    final Log logger = getLogger();
    final boolean debugEnabled = logger.isDebugEnabled();

    if (getSessionCache().isClientServer()) {
      if (debugEnabled) {
        logger.debug("Locally clearing sessions.");
      }
      getSessionCache().getOperatingRegion().localClear();
    }

    if (debugEnabled) {
      logger.debug("Unloading complete");
    }
  }
Clear the local cache to avoid ClassCastException if container is being reloaded.
extensions/geode-modules/src/main/java/org/apache/geode/modules/session/catalina/DeltaSessionManager.java