dataroaring commented on code in PR #20308: URL: https://github.com/apache/doris/pull/20308#discussion_r1212669291
########## be/src/olap/delta_writer.cpp: ########## @@ -267,6 +267,7 @@ Status DeltaWriter::write(const vectorized::Block* block, const std::vector<int> } Status DeltaWriter::_flush_memtable_async() { + _mem_table->assign_seq_id(); Review Comment: assgin_segment_id is a better name. ########## be/src/olap/delta_writer.cpp: ########## @@ -209,9 +209,9 @@ Status DeltaWriter::init() { _reset_mem_table(); // create flush handler - // unique key should flush serial because we need to make sure same key should sort - // in the same order in all replica. - bool should_serial = _tablet->keys_type() == KeysType::UNIQUE_KEYS; + // by assigning seq_id to memtable before submiting to flush executor, + // we can make sure same keys sort in the same order in all replicas. + bool should_serial = false; Review Comment: An unnecessary local variable. -- 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-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org