zhongqishang commented on code in PR #3672:
URL: https://github.com/apache/amoro/pull/3672#discussion_r2214827342
##########
amoro-format-iceberg/src/main/java/org/apache/amoro/table/TableProperties.java:
##########
@@ -42,6 +42,11 @@ private TableProperties() {}
public static final String TABLE_CREATE_TIME = "table.create-timestamp";
public static final long TABLE_CREATE_TIME_DEFAULT = 0L;
+ /** table comment related properties */
+ public static final String COMMENT = "comment";
+
+ public static final String COMMENT_DEFAULT = "";
Review Comment:
I suggest that don't need a default value, and that it would be more
user-friendly if the page doesn't show anything without comment. WDYT?
##########
amoro-ams/src/main/java/org/apache/amoro/server/dashboard/MixedAndIcebergTableDescriptor.java:
##########
@@ -171,9 +171,16 @@ public ServerTableMeta getTableDetail(AmoroTable<?>
amoroTable) {
}
String averageFileSize = AmsUtil.byteToXB(tableFileCnt == 0 ? 0 :
tableSize / tableFileCnt);
long records = getRecordsOfTable(table);
+ String comment =
+ table.properties().getOrDefault(TableProperties.COMMENT,
TableProperties.COMMENT_DEFAULT);
TableSummary tableSummary =
new TableSummary(
- tableFileCnt, AmsUtil.byteToXB(tableSize), averageFileSize,
records, tableFormat);
+ tableFileCnt,
+ AmsUtil.byteToXB(tableSize),
+ averageFileSize,
+ records,
+ tableFormat,
+ comment);
Review Comment:
Maybe we can add comment to
`org.apache.amoro.table.descriptor.ServerTableMeta`.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]