rdblue commented on a change in pull request #1815:
URL: https://github.com/apache/iceberg/pull/1815#discussion_r529803489



##########
File path: flink/src/main/java/org/apache/iceberg/flink/FlinkCatalog.java
##########
@@ -619,7 +625,23 @@ public void alterPartitionColumnStatistics(ObjectPath 
tablePath, CatalogPartitio
   @Override
   public List<CatalogPartitionSpec> listPartitions(ObjectPath tablePath)
       throws CatalogException {
-    throw new UnsupportedOperationException();
+    Table table = icebergCatalog.loadTable(toIdentifier(tablePath));
+    CloseableIterable<FileScanTask> tasks = table.newScan().planFiles();
+    List<DataFile> dataFiles = 
Lists.newArrayList(CloseableIterable.transform(tasks, FileScanTask::file));
+
+    Set<CatalogPartitionSpec> set = Sets.newHashSet();
+    for (DataFile dataFile : dataFiles) {
+      Map<String, String> map = new HashMap<>();

Review comment:
       We like to use the factory method instead: `Maps.newHashMap()`.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to