[fix](statistics)Fix column stats trigger info bug (#28303)
Before, we didn't update the jobType info in ColStatsMeta. This will case the jobType always be the type when it first be set. For example, if we manually analyzed table, the jobType will always be MANUAL, even if this table is auto analyzed again later.
This commit is contained in:
@ -361,8 +361,6 @@ public class AnalysisManager implements Writable {
|
||||
}
|
||||
recordAnalysisJob(jobInfo);
|
||||
analysisJobIdToTaskMap.put(jobInfo.jobId, analysisTaskInfos);
|
||||
// TODO: maybe we should update table stats only when all task succeeded.
|
||||
updateTableStats(jobInfo);
|
||||
if (!jobInfo.scheduleType.equals(ScheduleType.PERIOD)) {
|
||||
analysisTaskInfos.values().forEach(taskExecutor::submitTask);
|
||||
}
|
||||
|
||||
@ -141,6 +141,7 @@ public class TableStatsMeta implements Writable {
|
||||
colStatsMeta.updatedTime = updatedTime;
|
||||
colStatsMeta.analysisType = analyzedJob.analysisType;
|
||||
colStatsMeta.analysisMethod = analyzedJob.analysisMethod;
|
||||
colStatsMeta.jobType = analyzedJob.jobType;
|
||||
}
|
||||
}
|
||||
jobType = analyzedJob.jobType;
|
||||
|
||||
Reference in New Issue
Block a user