liaoxin01 commented on code in PR #30157:
URL: https://github.com/apache/doris/pull/30157#discussion_r1460483316
##########
be/src/vec/sink/writer/vtablet_writer_v2.cpp:
##########
@@ -431,15 +431,27 @@ Status
VTabletWriterV2::_write_memtable(std::shared_ptr<vectorized::Block> block
.is_high_priority = _is_high_priority,
.write_file_cache = _write_file_cache,
};
+ bool index_not_found = true;
for (const auto& index : _schema->indexes()) {
if (index->index_id == rows.index_id) {
req.slots = &index->slots;
req.schema_hash = index->schema_hash;
+ index_not_found = false;
break;
}
}
+ if (index_not_found) {
+ LOG(WARNING) << "index " << rows.index_id
+ << " not found in schema, load_id=" <<
print_id(_load_id);
+ return static_cast<std::unique_ptr<DeltaWriterV2>>(nullptr);
Review Comment:
```suggestion
return std::unique_ptr<DeltaWriterV2>(nullptr);
```
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]