docs: private AbstractTopology recoverPartitions(AbstractTopology topology, String haGroup, Set<Integer> recoverPartitions) {
  
          long version = topology.version;
          if (!recoverPartitions.isEmpty()) {
              // In rejoin case, partition list from the rejoining node could be out of range if the rejoining
              // host is a previously elastic removed node or some other used nodes, if out of range, do not restore
              if (Collections.max(recoverPartitions) > Collections.max(m_cartographer.getPartitions())) {
                  recoverPartitions.clear();
              }
          }
          AbstractTopology recoveredTopo = AbstractTopology.mutateRecoverTopology(topology,
                  m_messenger.getLiveHostIds(),
                  m_messenger.getHostId(),
                  haGroup,
                  recoverPartitions);
          if (recoveredTopo == null) {
              return null;
          }
          List<Integer> partitions = Lists.newArrayList(recoveredTopo.getPartitionIdList(m_messenger.getHostId()));
          if (partitions != null && partitions.size() == m_catalogContext.getNodeSettings().getLocalSitesCount()) {
              TopologyZKUtils.updateTopologyToZK(m_messenger.getZK(), recoveredTopo);
          }
          if (version < recoveredTopo.version && !recoverPartitions.isEmpty()) {
              consoleLog.info("Partition placement layout has been restored for rejoining.");
          }
          return recoveredTopo;
      }