mirror of
https://github.com/crawlab-team/crawlab.git
synced 2026-01-21 17:21:09 +01:00
feat: Update notification trigger patterns and add alert trigger
The code changes modify the notification constants and models to update the trigger patterns for tasks and nodes. Additionally, a new trigger for alerts is added to the constants. This change allows for more flexible matching of notification triggers.
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
package constants
|
||||
|
||||
const (
|
||||
NotificationTriggerTargetTask = "task"
|
||||
NotificationTriggerTargetNode = "node"
|
||||
NotificationTriggerPatternTask = "^task"
|
||||
NotificationTriggerPatternNode = "^node"
|
||||
)
|
||||
|
||||
const (
|
||||
@@ -12,6 +12,7 @@ const (
|
||||
NotificationTriggerNodeStatusChange = "node_status_change"
|
||||
NotificationTriggerNodeOnline = "node_online"
|
||||
NotificationTriggerNodeOffline = "node_offline"
|
||||
NotificationTriggerAlert = "alert"
|
||||
)
|
||||
|
||||
const (
|
||||
|
||||
Reference in New Issue
Block a user