Documentation ¶
Index ¶
- func DomainToURL(domain string) string
- func ObjectReference(ctx context.Context, dynamicClient dynamic.Interface, namespace string, ...) (duck.Marshalable, error)
- func ResourceInterface(dynamicClient dynamic.Interface, namespace string, ref *corev1.ObjectReference) (dynamic.ResourceInterface, error)
- func SubscriberSpec(ctx context.Context, dynamicClient dynamic.Interface, namespace string, ...) (string, error)
- type AddressableInformer
- type SinkReconciler
- type Track
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DomainToURL ¶
DomainToURL converts a domain into an HTTP URL.
func ObjectReference ¶
func ObjectReference(ctx context.Context, dynamicClient dynamic.Interface, namespace string, ref *corev1.ObjectReference) (duck.Marshalable, error)
ObjectReference resolves an object based on an ObjectReference.
func ResourceInterface ¶
func ResourceInterface(dynamicClient dynamic.Interface, namespace string, ref *corev1.ObjectReference) (dynamic.ResourceInterface, error)
ResourceInterface creates a resource interface for the given ObjectReference.
func SubscriberSpec ¶
func SubscriberSpec(ctx context.Context, dynamicClient dynamic.Interface, namespace string, s *v1alpha1.SubscriberSpec, track Track) (string, error)
SubscriberSpec resolves the Spec.Call object. If it's an ObjectReference, it will resolve the object and treat it as an Addressable. If it's a DNSName, then it's used as is. TODO: Once Service Routes, etc. support Callable, use that.
Types ¶
type AddressableInformer ¶
type AddressableInformer interface { // TrackInNamespace returns a function that can be used to watch arbitrary Addressables in the same // namespace as obj. Any change will cause a callback for obj. TrackInNamespace(tracker tracker.Interface, obj metav1.Object) func(corev1.ObjectReference) error }
AddressableInformer is an informer that allows tracking arbitrary Addressables.
func NewAddressableInformer ¶
func NewAddressableInformer(opt reconciler.Options) AddressableInformer
NewAddressableInformer creates a new AddressableInformer.
type SinkReconciler ¶
type SinkReconciler struct {
// contains filtered or unexported fields
}
SinkReconciler is a helper for Sources. It triggers reconciliation on creation, updates to or deletion of the source's sink.
func NewSinkReconciler ¶
func NewSinkReconciler(opt reconciler.Options, callback func(string)) *SinkReconciler
NewSinkReconciler creates and initializes a new SinkReconciler
func (*SinkReconciler) GetSinkURI ¶
func (r *SinkReconciler) GetSinkURI(sinkObjRef *corev1.ObjectReference, source interface{}, sourceDesc string) (string, error)
GetSinkURI registers the given object reference with the tracker and if possible, retrieves the sink URI
type Track ¶
type Track func(corev1.ObjectReference) error