diff --git a/engine/stats.go b/engine/stats.go index d7e4e0bed..40ec3fb1d 100644 --- a/engine/stats.go +++ b/engine/stats.go @@ -361,8 +361,9 @@ func (sS *StatS) processEvent(ctx *context.Context, tnt string, args *utils.CGRE } } - if sS.processThresholds(ctx, matchSQs, args.APIOpts) != nil || - withErrors { + + err = sS.processThresholds(ctx, matchSQs, args.APIOpts) + if withErrors { err = utils.ErrPartiallyExecuted } @@ -373,7 +374,10 @@ func (sS *StatS) processEvent(ctx *context.Context, tnt string, args *utils.CGRE } if len(promIDs) != 0 { if err = exportToPrometheus(matchSQs, utils.NewStringSet(promIDs)); err != nil { - return + utils.Logger.Warning( + fmt.Sprintf(" Failed to export the queues to Prometheus: error: %s", + err.Error())) + err = utils.ErrPartiallyExecuted } } return