@Override
  public void cleanup(int sessionId) {
    sessions.remove(sessionId);

    var expiredKeys = adhocReferenceMap.entrySet().stream()
      .filter(entry -> entry.getValue().get() == null)
      .map(Map.Entry::getKey)
      .toList();

    for (String key : expiredKeys) {
      adhocReferenceMap.remove(key);
    }
  }
@Override
  public void cleanup(int sessionId)