You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Hello
Currently as of writing the format of the message string returned in getNotificationMessage includes a static description of the related cluster plus the actual message(s).
logger.V(logs.LogDebug).Info("all liveness checks are passing")
} else {
logger.V(logs.LogDebug).Info("some of the liveness checks are not passing")
}
returnmessage, passing
}
This makes it rather difficult to implement custom formatting for each of the notification implementation. (e.g. Slack, Teams).
For example I would like in the future to propose changing the Teams notification to use a more rich format instead of the current bland messages.
Describe the solution you'd like
My suggestion would be to just return the message string without the fmt.Sprintf("cluster %s:%s/%s \n", clusterType, clusterNamespace, clusterName) prefix, and let each implementation choose how it should be shown.
This would make it more flexible for each of the notification integration to tailor how it should look, since they are quite different from each other and each of them have different features available.
Describe alternatives you've considered
Alternatively beside the original message string, you could also just return a list of the messages, so each integration can pick and choose between original format or a more free format. This would keep it more DRY, since Im guessing that most of the notifications integration will keep the original format.
Currently these Messages are quite simple, so it would be cool in the furture if you could get a more parsable return from getNotificationMessage(), as Teams adaptive cards have a lot of features like formatting.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
Hello
Currently as of writing the format of the message string returned in
getNotificationMessage
includes a static description of the related cluster plus the actual message(s).healthcheck-manager/controllers/notification.go
Lines 248 to 270 in be3a33b
This makes it rather difficult to implement custom formatting for each of the notification implementation. (e.g. Slack, Teams).
For example I would like in the future to propose changing the Teams notification to use a more rich format instead of the current bland messages.
Describe the solution you'd like
My suggestion would be to just return the message string without the
fmt.Sprintf("cluster %s:%s/%s \n", clusterType, clusterNamespace, clusterName)
prefix, and let each implementation choose how it should be shown.This would make it more flexible for each of the notification integration to tailor how it should look, since they are quite different from each other and each of them have different features available.
Describe alternatives you've considered
Alternatively beside the original
message
string, you could also just return a list of the messages, so each integration can pick and choose between original format or a more free format. This would keep it more DRY, since Im guessing that most of the notifications integration will keep the original format.Additional context
in #162 I hinted at this
The text was updated successfully, but these errors were encountered: