xuefuz commented on a change in pull request #10296: [FLINK-14691][table]Add 
use/create/drop/alter database operation and support it in flink/blink planner
URL: https://github.com/apache/flink/pull/10296#discussion_r349856614
 
 

 ##########
 File path: 
flink-table/flink-table-common/src/main/java/org/apache/flink/table/catalog/Catalog.java
 ##########
 @@ -141,10 +141,14 @@ void createDatabase(String name, CatalogDatabase 
database, boolean ignoreIfExist
         * @param ignoreIfNotExists Flag to specify behavior when the database 
does not exist:
         *                          if set to false, throw an exception,
         *                          if set to true, do nothing.
+        * @param isRestrict        Flag to specify behavior when the database 
contains table:
+        *                          if set to false, delete all tables in the 
database and then delete the database,
+        *                          if set to true, throw an exception.
         * @throws DatabaseNotExistException if the given database does not 
exist
+        * @throws DatabaseNotEmptyException if the given database is not empty
         * @throws CatalogException in case of any runtime exception
         */
-       void dropDatabase(String name, boolean ignoreIfNotExists) throws 
DatabaseNotExistException,
+       void dropDatabase(String name, boolean ignoreIfNotExists, boolean 
isRestrict) throws DatabaseNotExistException,
 
 Review comment:
   I think we should add a new API instead of changing existing one.

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to