mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-19 10:46:58 +08:00
Merge pull request #6147 from rainzm/fix/scaling_notification
fix/monitor: AutoScalingNotifier.ShouldNotify should call NotifierBase.ShouldNotify
This commit is contained in:
@@ -63,9 +63,10 @@ func (as *AutoScalingNotifier) Notify(ctx *alerting.EvalContext, data jsonutils.
|
||||
return nil
|
||||
}
|
||||
|
||||
func (as *AutoScalingNotifier) ShouldNotify(ctx context.Context, evalContext *alerting.EvalContext, notificationState *models.SAlertnotification) bool {
|
||||
if evalContext.Rule.State == monitor.AlertStateOK || evalContext.NoDataFound {
|
||||
func (as *AutoScalingNotifier) ShouldNotify(ctx context.Context, evalContext *alerting.EvalContext,
|
||||
notificationState *models.SAlertnotification) bool {
|
||||
if evalContext.NoDataFound {
|
||||
return false
|
||||
}
|
||||
return true
|
||||
return as.NotifierBase.ShouldNotify(ctx, evalContext, notificationState)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user