jerryshao commented on code in PR #8879:
URL: https://github.com/apache/gravitino/pull/8879#discussion_r2460065949


##########
catalogs/catalog-generic-lakehouse/src/main/java/org/apache/gravitino/catalog/lakehouse/GenericLakehouseCatalogOperations.java:
##########
@@ -160,7 +193,66 @@ public Table createTable(
       SortOrder[] sortOrders,
       Index[] indexes)
       throws NoSuchSchemaException, TableAlreadyExistsException {
-    throw new UnsupportedOperationException("Not implemented yet.");
+    String format = properties.getOrDefault("format", "lance");
+    String tableLocation = calculateTableLocation(ident, properties);
+    Map<String, String> newProperties = Maps.newHashMap(properties);
+    newProperties.put("location", tableLocation);
+
+    LakehouseCatalogOperations lakehouseCatalogOperations =
+        SUPPORTED_FORMATS.compute(
+            format,
+            (k, v) ->
+                v == null
+                    ? createLakehouseCatalogOperations(
+                        format, properties, catalogInfo, propertiesMetadata)
+                    : v);

Review Comment:
   This map seems have threading issue if the request coming in concurrently.



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