imay commented on a change in pull request #2604: [env] Add CREATE_OR_OPEN and 
rename existing open modes
URL: https://github.com/apache/incubator-doris/pull/2604#discussion_r361659107
 
 

 ##########
 File path: be/src/env/env.h
 ##########
 @@ -29,19 +29,21 @@ class Env {
 public:
     // Governs if/how the file is created.
     //
-    // enum value                      | file exists       | file does not 
exist
-    // 
--------------------------------+-------------------+--------------------
-    // CREATE_IF_NON_EXISTING_TRUNCATE | opens + truncates | creates
-    // CREATE_NON_EXISTING             | fails             | creates
-    // OPEN_EXISTING                   | opens             | fails
-    enum CreateMode {
-        CREATE_IF_NON_EXISTING_TRUNCATE,
-        CREATE_NON_EXISTING,
-        OPEN_EXISTING
+    // enum value                   | file exists       | file does not exist
+    // -----------------------------+-------------------+--------------------
+    // CREATE_OR_OPEN_WITH_TRUNCATE | opens + truncates | creates
+    // CREATE_OR_OPEN               | opens             | creates
+    // MUST_CREATE                  | fails             | creates
+    // MUST_EXIST                   | opens             | fails
+    enum OpenMode {
+        CREATE_OR_OPEN_WITH_TRUNCATE,
+        CREATE_OR_OPEN,
+        MUST_CREATE,
+        MUST_EXIST
 
 Review comment:
   `CREATE_OR_OPEN` starts with a verb, and MUST_CREATE is not. we should keep 
it consistent.

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

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to