code: int calculateMaxProgress(MappingTarget mappingTarget) {
      int batches = mappingTarget.getEntityMappings().stream().mapToInt(this::countBatches).sum();
      if (mappingTarget.hasSelfReferences()) {
        batches *= 2;
      }
      return batches;
    }
docs: Package-private for testablility