Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
  • Loading branch information
hawkingrei committed Nov 8, 2023
1 parent 8963f70 commit 8709330
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions pkg/executor/analyze.go
Original file line number Diff line number Diff line change
Expand Up @@ -519,23 +519,19 @@ func (e *AnalyzeExec) analyzeWorker(taskCh <-chan *analyzeTask, resultsCh chan<-
if r := recover(); r != nil {
logutil.BgLogger().Error("analyze worker panicked", zap.Any("recover", r), zap.Stack("stack"))
metrics.PanicCounter.WithLabelValues(metrics.LabelAnalyze).Inc()
var job *statistics.AnalyzeJob
if task != nil {
job = task.job
}
resultsCh <- &statistics.AnalyzeResults{
Err: getAnalyzePanicErr(r),
Job: job,
Job: task.job,
}
}
}()
failpoint.Inject("handleAnalyzeWorkerPanic", nil)
for {
var ok bool
task, ok = <-taskCh
if !ok {
break
}
failpoint.Inject("handleAnalyzeWorkerPanic", nil)
StartAnalyzeJob(e.Ctx(), task.job)
switch task.taskType {
case colTask:
Expand Down

0 comments on commit 8709330

Please sign in to comment.