private void printSummary()

in iceberg-catalog-migrator/cli/src/main/java/org/apache/polaris/iceberg/catalog/migrator/cli/BaseRegisterCommand.java [254:287]


  private void printSummary(CatalogMigrationResult result) {
    consoleLog.info("Summary: ");
    if (!result.registeredTableIdentifiers().isEmpty()) {
      consoleLog.info(
          "Successfully {} {} tables from {} catalog to {} catalog.",
          operated(),
          result.registeredTableIdentifiers().size(),
          sourceCatalogOptions.type.name(),
          targetCatalogOptions.type.name());
    }
    if (!result.failedToRegisterTableIdentifiers().isEmpty()) {
      consoleLog.error(
          "Failed to {} {} tables from {} catalog to {} catalog. "
              + "Please check the `catalog_migration.log` file for the failure reason. "
              + "Failed identifiers are written into `{}`. "
              + "Retry with that file using `--identifiers-from-file` option "
              + "if the failure is because of network/connection timeouts.",
          operate(),
          result.failedToRegisterTableIdentifiers().size(),
          sourceCatalogOptions.type.name(),
          targetCatalogOptions.type.name(),
          FAILED_IDENTIFIERS_FILE);
    }
    if (!result.failedToDeleteTableIdentifiers().isEmpty()) {
      consoleLog.error(
          "Failed to delete {} tables from {} catalog. "
              + "Please check the `catalog_migration.log` file for the failure reason. "
              + "{}Failed to delete identifiers are written into `{}`.",
          result.failedToDeleteTableIdentifiers().size(),
          sourceCatalogOptions.type.name(),
          System.lineSeparator(),
          FAILED_TO_DELETE_AT_SOURCE_FILE);
    }
  }