Skip to content

Commit

Permalink
refactor: sub rule event enable run notify script
Browse files Browse the repository at this point in the history
  • Loading branch information
710leo committed Aug 27, 2024
1 parent 86d478a commit 1f7314f
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions alert/dispatch/dispatch.go
Original file line number Diff line number Diff line change
Expand Up @@ -272,12 +272,13 @@ func (e *Dispatch) Send(rule *models.AlertRule, event *models.AlertCurEvent, not
sender.SingleSendWebhooks(e.ctx, notifyTarget.ToWebhookList(), event, e.Astats)
}

// handle plugin call
go sender.MayPluginNotify(e.ctx, e.genNoticeBytes(event), e.notifyConfigCache.
GetNotifyScript(), e.Astats, event)

if !isSubscribe {
// handle ibex callbacks
e.HandleIbex(rule, event)
// handle plugin call
go sender.MayPluginNotify(e.ctx, e.genNoticeBytes(event), e.notifyConfigCache.
GetNotifyScript(), e.Astats, event)
}
}

Expand Down

0 comments on commit 1f7314f

Please sign in to comment.