xuefuz commented on a change in pull request #8390: [FLINK-12469][table] Clean up catalog API on default/current database URL: https://github.com/apache/flink/pull/8390#discussion_r283902136
########## File path: flink-table/flink-table-api-java/src/main/java/org/apache/flink/table/catalog/GenericInMemoryCatalog.java ########## @@ -65,9 +64,15 @@ private final Map<ObjectPath, Map<CatalogPartitionSpec, CatalogColumnStatistics>> partitionColumnStats; public GenericInMemoryCatalog(String name) { + this(name, DEFAULT_DB); + } + + public GenericInMemoryCatalog(String name, String defaultDatabase) { Review comment: Since we will have PR coming for YAML file structure for catalogs, let's defer the discussion until we see it. Now as far as I am concerned, I don't see a use case for a user to create a default DB before creating a catalog. It's also common for a db product to create default db automatically. If user needs there specific databases, they can create their own (possibly via DDL). Our in-memory catalog is following the suite except we allow user specific a name other than "default" with the change here. This addition seems to me even optional. Nevertheless, if we find it necessary that taking a database created by user to instantiate the in-memory DB, we can add it at that time. ---------------------------------------------------------------- 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: us...@infra.apache.org With regards, Apache Git Services