You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2021/09/24 10:08:06 UTC

[GitHub] [incubator-doris] morningman commented on a change in pull request #6695: [BUG] If new group name is the same as old group name when mod table colocate group name, the group has been in an unstable state

morningman commented on a change in pull request #6695:
URL: https://github.com/apache/incubator-doris/pull/6695#discussion_r715486949



##########
File path: fe/fe-core/src/main/java/org/apache/doris/catalog/Catalog.java
##########
@@ -5278,6 +5278,14 @@ public void modifyTableColocate(Database db, OlapTable table, String colocateGro
         GroupId groupId = null;
         if (!Strings.isNullOrEmpty(colocateGroup)) {
             String fullGroupName = db.getId() + "_" + colocateGroup;
+            //When the new name is the same as the old name, we return it to prevent npe
+            if (!Strings.isNullOrEmpty(oldGroup)) {
+                String oldFullGroupName = db.getId() + "_" + oldGroup;
+                if (oldFullGroupName.equals(fullGroupName)) {
+                    LOG.warn("modify table[{}] group name same as old group name,skilled modify.", table.getName());

Review comment:
       ```suggestion
                       LOG.warn("modify table[{}] group name same as old group name, skip.", table.getName());
   ```




-- 
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: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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