kangpinghuang commented on a change in pull request #2294: Add convert tablet 
rowset type
URL: https://github.com/apache/incubator-doris/pull/2294#discussion_r356948485
 
 

 ##########
 File path: fe/src/main/java/org/apache/doris/alter/SchemaChangeHandler.java
 ##########
 @@ -842,11 +843,24 @@ private void createJob(long dbId, OlapTable olapTable, 
Map<Long, LinkedList<Colu
         // property 3: timeout
         long timeoutSecond = PropertyAnalyzer.analyzeTimeout(propertyMap, 
Config.alter_table_timeout_second);
 
+        // Parse storage_format property
+        // sql: alter table tablet_name set ("storage_format" = "v2")
+        // Use this sql to convert all tablets(base and rollup index) to 
segment v2.
+        // analyzeStorageFormat will parse the properties to decide whether 
storage format is set to v2.
+        // If true, fire a schema change job to achieve it.
+        boolean changeStorageFormat = 
PropertyAnalyzer.analyzeStorageFormat(propertyMap);
 
 Review comment:
   > If the storage format of this table is already v2, will another schema 
change job be created?
   
   This function will only be used to force to convert a v1 table(maybe 
partially is v1) to v2 manually. Should use it before check the table. It is 
for simplicity.
   And more, Because In FE, we do not store the storage format information of 
table, So it is hard to reject to convert a v2 table.

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