896a56ada8
* migrate to new manifest format * rename app to alerting.notifications to not conflict with rules * disable custom field selectors as they are not supported in appinstaller
25 lines
543 B
Go
25 lines
543 B
Go
package v0alpha1
|
|
|
|
const UserDefinedRoutingTreeName = "user-defined"
|
|
|
|
func (o *RoutingTree) GetProvenanceStatus() string {
|
|
if o == nil || o.Annotations == nil {
|
|
return ""
|
|
}
|
|
s, ok := o.Annotations[ProvenanceStatusAnnotationKey]
|
|
if !ok || s == "" {
|
|
return ProvenanceStatusNone
|
|
}
|
|
return s
|
|
}
|
|
|
|
func (o *RoutingTree) SetProvenanceStatus(status string) {
|
|
if o.Annotations == nil {
|
|
o.Annotations = make(map[string]string, 1)
|
|
}
|
|
if status == "" {
|
|
status = ProvenanceStatusNone
|
|
}
|
|
o.Annotations[ProvenanceStatusAnnotationKey] = status
|
|
}
|