-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
45 changed files
with
294 additions
and
197 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,16 @@ | ||
package notificationv2 | ||
|
||
const ( | ||
// The list of action results. | ||
EnabledResult = "Enabled" | ||
DisableResult = "Disabled" | ||
DeletedResult = "Deleted" | ||
) | ||
|
||
// ActionResult contains result of action with notification rule. | ||
type ActionResult struct { | ||
Result string `json:"result"` | ||
Result Result `json:"result"` | ||
} | ||
|
||
// Result contains string status of notification action result. | ||
type Result string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package notificationv2 | ||
|
||
const ( | ||
// Types of action that notification rule will have after creating. It is used to create an alert. | ||
CreateAlertActionType = "create-alert" | ||
AcknowledgedAlertActionType = "acknowledged-alert" | ||
ClosedAlertActionType = "closed-alert" | ||
AssignedAlertActionType = "assigned-alert" | ||
AddNoteActionType = "add-note" | ||
ScheduleStartActionType = "schedule-start" | ||
ScheduleEndActionType = "schedule-end" | ||
IncomingCallRoutingActionType = "incoming-call-routing" | ||
) | ||
|
||
// ActionType is the type of notification action. Instead of | ||
type ActionType string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package notificationv2 | ||
|
||
const ( | ||
// The list of matches which are used for creating criteria of notification. | ||
MatchAllType = "match-all" | ||
MatchAnyConditionsType = "match-any-condition" | ||
MatchAllConditionsType = "match-all-conditions" | ||
) | ||
|
||
// ConditionType is a type of matching of alert fields, which is used for building criteria of notification. | ||
type ConditionType string |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package notificationv2 | ||
|
||
const ( | ||
// The list of week days. These strings are used for generate time restrictions. | ||
Monday = "monday" | ||
Tuesday = "tuesday" | ||
Wednesday = "wednesday" | ||
Thursday = "thursday" | ||
Friday = "friday" | ||
Saturday = "saturday" | ||
Sunday = "sunday" | ||
) | ||
|
||
// Day is the text representation of day name of week. | ||
type Day string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package notificationv2 | ||
|
||
const ( | ||
// The list of fields, which are used for build filter of alerts. | ||
ActionsField = "actions" | ||
AliasField = "alias" | ||
DescriptionField = "description" | ||
EntityField = "entity" | ||
MessageField = "message" | ||
RecipientsField = "recipients" | ||
SourceField = "source" | ||
TeamsField = "teams" | ||
ExtraPropertiesField = "extra-properties" | ||
) | ||
|
||
// Field is the name of alert field, which is used to build filter of alerts. | ||
type Field string |
Oops, something went wrong.