diqiu50 commented on code in PR #11073:
URL: https://github.com/apache/gravitino/pull/11073#discussion_r3286685969


##########
catalogs/catalog-glue/src/main/java/org/apache/gravitino/catalog/glue/GlueIcebergTableHelper.java:
##########
@@ -132,17 +136,23 @@ static boolean 
isIcebergTable(software.amazon.awssdk.services.glue.model.Table g
   /**
    * Creates an Iceberg {@link Catalog} backed by AWS Glue.
    *
-   * @param config Gravitino catalog configuration (region, credentials, 
endpoint, etc.)
+   * @param config Gravitino catalog configuration (region, credentials, 
endpoint, etc.). Must
+   *     contain {@code aws-region} and {@code warehouse}.
    * @return an initialized Iceberg Glue catalog
+   * @throws IllegalArgumentException if {@code aws-region} or {@code 
warehouse} is not configured
    */
   static Catalog createGlueCatalog(Map<String, String> config) {
     String region = config.get(GlueConstants.AWS_REGION);
     Preconditions.checkArgument(region != null, "AWS region is required for 
Iceberg Glue catalog");
 
+    String warehouse = config.get(GlueConstants.WAREHOUSE);
+    Preconditions.checkArgument(
+        warehouse != null,
+        "Warehouse is required for Iceberg Glue catalog; configure '%s' on the 
catalog.",

Review Comment:
   Make it required.



-- 
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]

Reply via email to