This is an automated email from the ASF dual-hosted git repository. caiconghui pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/incubator-doris.git
The following commit(s) were added to refs/heads/master by this push: new 315b801 [Bug] Fix bug that the log message is wrong when ReportHandler can not find tablet meta from TabletInvertedIndex (#5497) 315b801 is described below commit 315b8015619aa4a8e9237800ef69bb659e7453d2 Author: caiconghui <55968745+caicong...@users.noreply.github.com> AuthorDate: Fri Mar 12 10:43:07 2021 +0800 [Bug] Fix bug that the log message is wrong when ReportHandler can not find tablet meta from TabletInvertedIndex (#5497) * [Bug] Fix bug that the log message is wrong when ReportHandler can not find tablet meta from TabletInvertedIndex Co-authored-by: caiconghui [蔡聪辉] <caicong...@xiaomi.com> --- .../src/main/java/org/apache/doris/master/ReportHandler.java | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/fe/fe-core/src/main/java/org/apache/doris/master/ReportHandler.java b/fe/fe-core/src/main/java/org/apache/doris/master/ReportHandler.java index 129f32f..1782b79 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/master/ReportHandler.java +++ b/fe/fe-core/src/main/java/org/apache/doris/master/ReportHandler.java @@ -949,10 +949,14 @@ public class ReportHandler extends Daemon { SystemInfoService infoService = Catalog.getCurrentSystemInfo(); TabletMeta tabletMeta = invertedIndex.getTabletMeta(tabletId); - long dbId = tabletMeta != null ? tabletMeta.getDbId() : TabletInvertedIndex.NOT_EXIST_VALUE; - long tableId = tabletMeta != null ? tabletMeta.getTableId() : TabletInvertedIndex.NOT_EXIST_VALUE; - long partitionId = tabletMeta != null ? tabletMeta.getPartitionId() : TabletInvertedIndex.NOT_EXIST_VALUE; - long indexId = tabletMeta != null ? tabletMeta.getIndexId() : TabletInvertedIndex.NOT_EXIST_VALUE; + if (tabletMeta == null || tabletMeta == TabletInvertedIndex.NOT_EXIST_TABLET_META) { + throw new MetaNotFoundException("tablet meta[" + tabletMeta + "] does not exist in tablet inverted index"); + } + + long dbId = tabletMeta.getDbId(); + long tableId = tabletMeta.getTableId(); + long partitionId = tabletMeta.getPartitionId(); + long indexId = tabletMeta.getIndexId(); int schemaHash = backendTabletInfo.getSchemaHash(); long version = backendTabletInfo.getVersion(); --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org