Skip to content

Commit

Permalink
Add stack to panic log (#90)
Browse files Browse the repository at this point in the history
  • Loading branch information
jswarren4 authored Dec 6, 2019
1 parent faa90bf commit cd85663
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rules/worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ func (w *v3Worker) singleRun() {
defer func() {
wg.Done()
if r := recover(); r != nil {
task.Logger.Error("Panic", zap.Any("recover", r))
task.Logger.Error("Panic", zap.Any("recover", r), zap.Stack("stack"))
}
}()
w.doWork(&task.Logger, &work.rule, w.engine.getLockTTLForRule(work.ruleIndex), func() { work.ruleTaskCallback(&task) }, work.metricsInfo, work.lockKey)
Expand Down

0 comments on commit cd85663

Please sign in to comment.