github-actions[bot] commented on code in PR #70996:
URL: https://github.com/apache/doris/pull/70996#discussion_r4691111326


##########
fe/fe-core/src/main/java/org/apache/doris/nereids/parser/LogicalPlanBuilder.java:
##########
@@ -7021,6 +7072,10 @@ private TableRefInfo 
visitBaseTableRefContext(BaseTableRefContext ctx) {
             tableAlias = ctx.tableAlias().strictIdentifier().getText();

Review Comment:
   [P1] Replace the direct `tableSample.fixedBlockSpec` access with 
`tableSample.getFixedBlockSpec()` (or a public predicate). `LogicalPlanBuilder` 
is in `org.apache.doris.nereids.parser`, while 
`analysis.TableSample.fixedBlockSpec` is declared `private`, so this PR fails 
FE compilation for all builds.



##########
gensrc/thrift/HeartbeatService.thrift:
##########
@@ -68,6 +68,7 @@ struct TBackendInfo {
     10: optional i64 be_mem // The physical memory available for use by BE.
     // Reserved for the Paimon Rust reader and aligned with its branch-4.1 
forward-port.
     11: optional bool supports_paimon_rust_reader
+    12: optional bool supports_fixed_block_sampling_v1

Review Comment:
   [P1] Allocate a fresh optional Thrift field id for 
`supports_fixed_block_sampling_v1` and preserve id 12 for 
`supports_native_file_encryption`. The base/master already use field 12 for 
native file encryption, so a rolling mixed-version heartbeat will misread one 
capability as the other and can route FIXED_BLOCK scans to an unsupported BE 
(while also corrupting the native-encryption capability).



##########
fe/fe-core/src/main/java/org/apache/doris/statistics/analysis/StatisticsAutoCollector.java:
##########
@@ -194,17 +196,25 @@ protected void processOneJob(TableIf table, 
Set<Pair<String, String>> columns, J
 
     protected boolean readyToSample(TableIf table, long rowCount, 
AnalysisManager manager,
             TableStatsMeta tableStatsStatus, boolean isSample) {
+        if (table instanceof OlapTable olap) {
+            long indexId = olap.getBaseIndexId();
+            if (isSample && rowCount > 0 && 
!StatisticsUtil.enableFixedBlockStatsSampling()
+                    && IndexSamplingSnapshot.reportedIndexRows(olap, indexId, 
true) == TableIf.UNKNOWN_ROW_COUNT) {
+                return false;
+            }

Review Comment:
   [P1] Keep `IndexSamplingSnapshot.reportState` behind the sampled/fixed-block 
path (or requeue on transient version-RPC failure). `readyToSample` now calls 
it for FULL auto-analyze too; in cloud this performs a meta-service RPC, and an 
`RpcException` becomes `AnalyzeSkipException` after `fetchJobFromMap` already 
removed the job, so the catch only logs and permanently drops that FULL analyze 
job instead of retrying it.



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

Reply via email to