You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by "kaijchen (via GitHub)" <gi...@apache.org> on 2023/10/30 08:26:54 UTC

[PR] [fix](move-memtable) fix DeltaWriterV2 profile use-after-free [doris]

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

   ## Proposed changes
   
   The sink who creates the delta writer may be closed while other sinks still using this delta writer.
   The parent profile is deconstructed and when the last sink trying to update the profile, it will meet use-after-free.
   
   To address this issue, we record the profile number in delta writer,
   and the last sink who close the delta writer will create and update the profile.
   
   ## 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


Re: [PR] [fix](move-memtable) fix DeltaWriterV2 profile use-after-free [doris]

Posted by "doris-robot (via GitHub)" <gi...@apache.org>.
doris-robot commented on PR #26110:
URL: https://github.com/apache/doris/pull/26110#issuecomment-1784753308

   (From new machine)TeamCity pipeline, clickbench performance test result:
    the sum of best hot time: 46.28 seconds
    stream load tsv:          556 seconds loaded 74807831229 Bytes, about 128 MB/s
    stream load json:         20 seconds loaded 2358488459 Bytes, about 112 MB/s
    stream load orc:          65 seconds loaded 1101869774 Bytes, about 16 MB/s
    stream load parquet:          32 seconds loaded 861443392 Bytes, about 25 MB/s
    insert into select:          29.2 seconds inserted 10000000 Rows, about 342K ops/s
    storage size: 17161969709 Bytes


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


Re: [PR] [fix](move-memtable) fix DeltaWriterV2 profile use-after-free [doris]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on code in PR #26110:
URL: https://github.com/apache/doris/pull/26110#discussion_r1375849853


##########
be/src/vec/sink/delta_writer_v2_pool.cpp:
##########
@@ -36,7 +37,7 @@ DeltaWriterV2* DeltaWriterV2Map::get_or_create(int64_t tablet_id,
     return _map.at(tablet_id).get();
 }
 
-Status DeltaWriterV2Map::close() {
+Status DeltaWriterV2Map::close(RuntimeProfile* profile) {

Review Comment:
   warning: method 'close' can be made static [readability-convert-member-functions-to-static]
   
   be/src/vec/sink/delta_writer_v2_pool.h:72:
   ```diff
   -     Status close(RuntimeProfile* profile);
   +     static Status close(RuntimeProfile* profile);
   ```
   



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


Re: [PR] [fix](move-memtable) fix DeltaWriterV2 profile use-after-free [doris]

Posted by "kaijchen (via GitHub)" <gi...@apache.org>.
kaijchen commented on PR #26110:
URL: https://github.com/apache/doris/pull/26110#issuecomment-1786170802

   run buildall


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


Re: [PR] [fix](move-memtable) fix DeltaWriterV2 profile use-after-free [doris]

Posted by "yiguolei (via GitHub)" <gi...@apache.org>.
yiguolei merged PR #26110:
URL: https://github.com/apache/doris/pull/26110


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


Re: [PR] [fix](move-memtable) fix DeltaWriterV2 profile use-after-free [doris]

Posted by "kaijchen (via GitHub)" <gi...@apache.org>.
kaijchen commented on PR #26110:
URL: https://github.com/apache/doris/pull/26110#issuecomment-1784703205

   run buildall


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


Re: [PR] [fix](move-memtable) fix DeltaWriterV2 profile use-after-free [doris]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #26110:
URL: https://github.com/apache/doris/pull/26110#issuecomment-1786490477

   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


Re: [PR] [fix](move-memtable) fix DeltaWriterV2 profile use-after-free [doris]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #26110:
URL: https://github.com/apache/doris/pull/26110#issuecomment-1786490504

   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


Re: [PR] [fix](move-memtable) fix DeltaWriterV2 profile use-after-free [doris]

Posted by "doris-robot (via GitHub)" <gi...@apache.org>.
doris-robot commented on PR #26110:
URL: https://github.com/apache/doris/pull/26110#issuecomment-1786208893

   (From new machine)TeamCity pipeline, clickbench performance test result:
    the sum of best hot time: 46 seconds
    stream load tsv:          552 seconds loaded 74807831229 Bytes, about 129 MB/s
    stream load json:         20 seconds loaded 2358488459 Bytes, about 112 MB/s
    stream load orc:          65 seconds loaded 1101869774 Bytes, about 16 MB/s
    stream load parquet:          32 seconds loaded 861443392 Bytes, about 25 MB/s
    insert into select:          29.0 seconds inserted 10000000 Rows, about 344K ops/s
    storage size: 17162106405 Bytes


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


Re: [PR] [fix](move-memtable) fix DeltaWriterV2 profile use-after-free [doris]

Posted by "doris-robot (via GitHub)" <gi...@apache.org>.
doris-robot commented on PR #26110:
URL: https://github.com/apache/doris/pull/26110#issuecomment-1786197240

   TeamCity be ut coverage result:
    Function Coverage: 37.36% (8468/22665) 
    Line Coverage: 29.66% (68507/231008)
    Region Coverage: 28.23% (35584/126028)
    Branch Coverage: 25.09% (18210/72568)
    Coverage Report: http://coverage.selectdb-in.cc/coverage/343b9def5086a12e93dfce80bfb6df8d4027f7ec_343b9def5086a12e93dfce80bfb6df8d4027f7ec/report/index.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