lipstick: use some existing label
@@ -26,13 +26,10 @@ import (
eventingduckv1alpha1 "knative.dev/eventing/pkg/apis/duck/v1alpha1"
eventingduckv1beta1 "knative.dev/eventing/pkg/apis/duck/v1beta1"
+ "knative.dev/eventing/pkg/apis/messaging"
messagingv1beta1 "knative.dev/eventing/pkg/apis/messaging/v1beta1"
)
-const (
- SubscribableAnnotationKey = "messaging.knative.dev/subscribable"
-)
-
var (
channelv1beta1GVK = (&messagingv1beta1.Channel{}).GetGroupVersionKind()
@@ -52,7 +49,7 @@ func getChannelDuckTypeSupportVersion(channelName string, client *lib.Client, ch
if !ok {
return "", errors.Wrapf(err, "Unable to cast the channel %v", metaResource)
}
- return channelable.ObjectMeta.Annotations[SubscribableAnnotationKey], nil
+ return channelable.ObjectMeta.Annotations[messaging.SubscribableDuckVersionAnnotation], nil
}
func getChannelAsV1Beta1Channelable(channelName string, client *lib.Client, channel metav1.TypeMeta) (*eventingduckv1beta1.Channelable, error) {
