jerryshao commented on code in PR #14874:
URL: https://github.com/apache/gravitino/pull/14874#discussion_r4534858434
##########
catalogs/catalog-glue/src/main/java/org/apache/gravitino/catalog/glue/GlueCatalogOperations.java:
##########
@@ -535,6 +541,9 @@ public GlueTable createTable(
validateColumns(columns);
// Iceberg tables delegate partitioning and ordering to
GlueIcebergTableHelper.
if (!isIceberg) {
+ for (Column column : columns) {
+ Preconditions.checkArgument(column.nullable(),
HIVE_NOT_NULL_UNSUPPORTED, column.name());
Review Comment:
Only top-level columns are checked, so NOT NULL on nested list/map/struct
fields is silently dropped on Hive tables (documented, but surprising).
Consider rejecting non-nullable nested types too, for consistency with the
top-level behavior.
--
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]