private int getNextId() {
    int id = nextKey.getAndIncrement();
    if (id <= 0) {
      // id must be >= 0 since ObjIdMap does not supports keys < 0.
      // We don't use 0 just to keep it reserved as an illegal id.
      synchronized (nextKey) {
        id = nextKey.get();
        if (id <= 0) {
          nextKey.set(1);
        }
      }
      id = nextKey.getAndIncrement();
    }
    return id;
  }
If true then use weak refs to reference the processors.
geode-core/src/main/java/org/apache/geode/distributed/internal/ProcessorKeeper21.java