github-actions[bot] commented on code in PR #69554:
URL: https://github.com/apache/doris/pull/69554#discussion_r4366121929
##########
fe/fe-core/src/main/java/org/apache/doris/service/FrontendServiceImpl.java:
##########
@@ -4917,19 +4917,19 @@ public TCreatePartitionResult
createPartition(TCreatePartitionRequest request) t
if (tablet instanceof CloudTablet) {
CloudTablet cloudTablet = (CloudTablet) tablet;
if (hasBeEndpoint) {
- bePathsMap =
cloudTablet.getNormalReplicaBackendPathMap(request.be_endpoint);
+ bePathsMap =
cloudTablet.getLoadReplicaBackendPathMap(request.be_endpoint);
} else {
if (cachedClusterId == null) {
cachedClusterId = ((CloudSystemInfoService)
Env.getCurrentSystemInfo())
.getCurrentClusterId();
}
- bePathsMap =
cloudTablet.getNormalReplicaBackendPathMapByClusterId(cachedClusterId);
+ bePathsMap =
cloudTablet.getLoadReplicaBackendPathMapByClusterId(cachedClusterId);
}
} else if (tabletSnapshot.isChangelog()) {
bePathsMap =
OlapTableSink.getChangelogColocatedReplicaBackendPathMap(
tabletSnapshot.changelogBaseTablet, tablet);
} else {
- bePathsMap = tablet.getNormalReplicaBackendPathMap();
+ bePathsMap = tablet.getLoadReplicaBackendPathMap();
Review Comment:
[P1] Reject empty load locations in dynamic partition RPCs
With `enable_memtable_on_sink_node=false`, an initially empty
automatic-partition table with one bucket and `replication_num=1` can lose rows
here. Replica creation uses `needScheduleAvailable()`, which admits alive
`disable_load` backends. If two new partitions land on a disabled and an
eligible BE respectively, this call removes the first partition's only target,
but the following quorum check only logs and the RPC returns OK.
`IndexChannel::init()` accepts the empty channel vector,
`VTabletWriter::_generate_one_index_channel_payload()` sends those rows
nowhere, and `IndexChannel::close_wait()` returns OK once all other channels
finish even when quorum fails. `DatabaseTransactionMgr.checkCommitStatus()`
derives involved partitions solely from commit infos, so the healthy partition
can commit while the wholly omitted partition is never checked. Before this
change, its alive backend remained in the map and received the writes.
Return a non-OK status for empty filtered locations before caching/returning
them, including the equivalent `replacePartition` path at line 5266. Add a
mixed-partition legacy-writer regression case; the V2 writer's empty-stream
rejection does not protect this supported path.
--
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]