use of io.confluent.ksql.tools.migrations.util.MigrationVersionInfoFormatter in project ksql by confluentinc.
the class MigrationInfoCommand method printAsTable.
private static void printAsTable(final List<MigrationFile> allMigrations, final Map<Integer, Optional<MigrationVersionInfo>> versionInfos) {
final MigrationVersionInfoFormatter formatter = new MigrationVersionInfoFormatter();
for (final MigrationFile migration : allMigrations) {
final MigrationVersionInfo versionInfo = versionInfos.get(migration.getVersion()).orElse(MigrationVersionInfo.pendingMigration(migration.getVersion(), migration.getName()));
formatter.addVersionInfo(versionInfo);
}
LOGGER.info(formatter.getFormatted());
}
Aggregations