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 2023/01/05 09:44:32 UTC

[GitHub] [doris] Lchangliang opened a new pull request, #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Lchangliang opened a new pull request, #15654:
URL: https://github.com/apache/doris/pull/15654

   # Proposed changes
   
   Issue Number: close #xxx
   
   ## Problem summary
   example:
   ```
   CREATE TABLE IF NOT EXISTS sale (
                   `user_id` LARGEINT NOT NULL COMMENT "用户id",
                   `date` DATE NOT NULL COMMENT "数据灌入日期时间",
                   `age` SMALLINT COMMENT "用户年龄",
                   `sex` TINYINT COMMENT "用户性别",
                   `city` VARCHAR(20) DEFAULT "beijing "COMMENT "用户所在城市",
                   `last_visit_date` DATETIME DEFAULT "1970-01-01 00:00:00" COMMENT "用户最后一次访问时间",
                   `last_update_date` DATETIME DEFAULT "1970-01-01 00:00:00" COMMENT "用户最后一次更新时间",
                   `last_visit_date_not_null` DATETIME NOT NULL DEFAULT "1970-01-01 00:00:00" COMMENT "用户最后一次访问时间",
                   `cost` BIGINT DEFAULT "0" COMMENT "用户总消费",
                   `max_dwell_time` INT DEFAULT "0" COMMENT "用户最大停留时间",
                   `min_dwell_time` INT DEFAULT "99999" COMMENT "用户最小停留时间")
               UNIQUE KEY(`user_id`, `date`, `age`, `sex`) DISTRIBUTED BY HASH(`user_id`)
               BUCKETS 1
               PROPERTIES ( "replication_num" = "1", "light_schema_change" = "true");
   
   insert datas
   
   ALTER TABLE sale ADD ROLLUP rollup(`user_id`,`date`,`age`, `sex`, `cost`);
   
   select rollup
   coredump
   ```
   
   ![image](https://user-images.githubusercontent.com/31928846/210744630-ff870a56-962d-46b2-aef2-fc785ddcf1ae.png)
   
   Because of the rollup has the same keys and the keys's order is same, BE will do linked schema change. The base tablet's segments will link to the new rollup tablet. But the unique id from the base tablet is starting from 0 and as the rollup tablet also. In this case, the unique id 4 in the base table is column 'city', but in the rollup tablet is 'cost'. It will decode the varcode page to bigint page so that be coredump. It needs to be rejected.
   
   I think that if a rollup add by link schema change, it means this rollup is redundant. It brings no additional revenue and wastes storage space. So 
   
   ## Checklist(Required)
   
   1. Does it affect the original behavior: 
       - [ ] Yes
       - [ ] No
       - [ ] I don't know
   2. Has unit tests been added:
       - [ ] Yes
       - [ ] No
       - [ ] No Need
   3. Has document been added or modified:
       - [ ] Yes
       - [ ] No
       - [ ] No Need
   4. Does it need to update dependencies:
       - [ ] Yes
       - [ ] No
   5. Are there any changes that cannot be rolled back:
       - [ ] Yes (If Yes, please explain WHY)
       - [ ] No
   
   ## Further comments
   
   If this is a relatively large or complex change, kick off the discussion at [dev@doris.apache.org](mailto:dev@doris.apache.org) by explaining why you chose the solution you did and what alternatives you considered, etc...
   
   


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1375025911

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1374856851

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1375237216

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1373361181

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1372004018

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1376630023

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1379911495

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] morningman commented on a diff in pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
morningman commented on code in PR #15654:
URL: https://github.com/apache/doris/pull/15654#discussion_r1062596841


##########
be/src/olap/schema_change.cpp:
##########
@@ -812,6 +812,17 @@ Status SchemaChangeHandler::_do_process_alter_tablet_v2(const TAlterTabletReqV2&
         sc_params.ref_rowset_readers = rs_readers;
         sc_params.delete_handler = &delete_handler;
         sc_params.base_tablet_schema = base_tablet_schema;
+        switch (request.alter_tablet_type) {

Review Comment:
   Need to check if `alter_tablet_type` is set.



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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1381996038

   PR approved by anyone and no changes requested.


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1381995952

   PR approved by at least one committer and no changes requested.


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1371995606

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1378151488

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1375163502

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1374853185

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1378325484

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1377266330

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] github-actions[bot] commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1376800375

   clang-tidy review says "All clean, LGTM! :+1:"


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


[GitHub] [doris] hello-stephen commented on pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
hello-stephen commented on PR #15654:
URL: https://github.com/apache/doris/pull/15654#issuecomment-1372292170

   TeamCity pipeline, clickbench performance test result:
    the sum of best hot time: 36.12 seconds
    load time: 658 seconds
    storage size: 17123232463 Bytes
    https://doris-community-test-1308700295.cos.ap-hongkong.myqcloud.com/tmp/20230105143034_clickbench_pr_74315.html


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


[GitHub] [doris] yiguolei merged pull request #15654: [Bugfix] (ROLLUP) fix the coredump when add rollup by link schema change

Posted by GitBox <gi...@apache.org>.
yiguolei merged PR #15654:
URL: https://github.com/apache/doris/pull/15654


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