mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-24 00:28:44 +05:00
Log prometheus errors instead of returning
This commit is contained in:
committed by
Dan Christian Bogos
parent
39f063d86a
commit
5531b5e7bd
@@ -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("<StatS> Failed to export the queues to Prometheus: error: %s",
|
||||
err.Error()))
|
||||
err = utils.ErrPartiallyExecuted
|
||||
}
|
||||
}
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user