@Override
  public Set<InternalDistributedMember> addMembershipListenerAndGetDistributionManagerIds(
      MembershipListener l) {
    return distribution.doWithViewLocked(() -> {
      addMembershipListener(l);
      return distribution.getMembersNotShuttingDown();
    });
  }
Add a membership listener and return other DistributionManagerIds as an atomic operation
geode-core/src/main/java/org/apache/geode/distributed/internal/ClusterDistributionManager.java