Documentation
¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the eventing v1alpha1 API group +k8s:openapi-gen=true +k8s:deepcopy-gen=package,register +k8s:conversion-gen=github.com/google/knative-gcp/pkg/apis/messaging +k8s:defaulter-gen=TypeMeta +groupName=messaging.cloud.run
Index ¶
- Constants
- Variables
- func Kind(kind string) schema.GroupKind
- func Resource(resource string) schema.GroupResource
- type Channel
- func (current *Channel) CheckImmutableFields(ctx context.Context, og apis.Immutable) *apis.FieldError
- func (in *Channel) DeepCopy() *Channel
- func (in *Channel) DeepCopyInto(out *Channel)
- func (in *Channel) DeepCopyObject() runtime.Object
- func (c *Channel) GetGroupVersionKind() schema.GroupVersionKind
- func (c *Channel) SetDefaults(ctx context.Context)
- func (c *Channel) Validate(ctx context.Context) *apis.FieldError
- type ChannelList
- type ChannelSpec
- type ChannelStatus
- func (in *ChannelStatus) DeepCopy() *ChannelStatus
- func (in *ChannelStatus) DeepCopyInto(out *ChannelStatus)
- func (cs *ChannelStatus) GetCondition(t apis.ConditionType) *apis.Condition
- func (cs *ChannelStatus) InitializeConditions()
- func (cs *ChannelStatus) IsReady() bool
- func (cs *ChannelStatus) MarkNoTopic(reason, messageFormat string, messageA ...interface{})
- func (cs *ChannelStatus) MarkTopicNotOwned(messageFormat string, messageA ...interface{})
- func (cs *ChannelStatus) MarkTopicOperating(reason, messageFormat string, messageA ...interface{})
- func (cs *ChannelStatus) MarkTopicReady()
- func (cs *ChannelStatus) SetAddress(url *apis.URL)
Constants ¶
const ( // ChannelConditionReady has status True when all subconditions below have // been set to True. ChannelConditionReady = apis.ConditionReady // ChannelConditionAddressable has status true when this Channel meets the // Addressable contract and has a non-empty url. ChannelConditionAddressable apis.ConditionType = "Addressable" // ChannelConditionTopicReady has status True when the Channel has had a // Pub/Sub topic created for it. ChannelConditionTopicReady apis.ConditionType = "TopicReady" )
Variables ¶
var ( SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) AddToScheme = SchemeBuilder.AddToScheme )
var SchemeGroupVersion = schema.GroupVersion{Group: messaging.GroupName, Version: "v1alpha1"}
SchemeGroupVersion is group version used to register these objects
Functions ¶
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group qualified GroupResource
Types ¶
type Channel ¶
type Channel struct { metav1.TypeMeta `json:",inline"` // +optional metav1.ObjectMeta `json:"metadata,omitempty"` // Spec defines the desired state of the Channel. Spec ChannelSpec `json:"spec,omitempty"` // Status represents the current state of the Channel. This data may be out of // date. // +optional Status ChannelStatus `json:"status,omitempty"` }
Channel is a resource representing an channel backed by Google Cloud Pub/Sub.
func (*Channel) CheckImmutableFields ¶
func (*Channel) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Channel.
func (*Channel) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Channel) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*Channel) GetGroupVersionKind ¶
func (c *Channel) GetGroupVersionKind() schema.GroupVersionKind
GetGroupVersionKind returns GroupVersionKind for Pub/Sub backed Channel.
func (*Channel) SetDefaults ¶
type ChannelList ¶
type ChannelList struct { metav1.TypeMeta `json:",inline"` // +optional metav1.ListMeta `json:"metadata,omitempty"` Items []Channel `json:"items"` }
ChannelList is a collection of Pub/Sub backed Channels.
func (*ChannelList) DeepCopy ¶
func (in *ChannelList) DeepCopy() *ChannelList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ChannelList.
func (*ChannelList) DeepCopyInto ¶
func (in *ChannelList) DeepCopyInto(out *ChannelList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ChannelList) DeepCopyObject ¶
func (in *ChannelList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ChannelSpec ¶
type ChannelSpec struct { // Secret is the credential to use to create, publish, and poll the Pub/Sub // Topic and Subscriptions. The value of the secret entry must be a // service account key in the JSON format // (see https://cloud.google.com/iam/docs/creating-managing-service-account-keys). // +optional Secret *corev1.SecretKeySelector `json:"secret,omitempty"` // Project is the ID of the Google Cloud Project that the Pub/Sub // Topic and Subscriptions will be created in. // +optional Project string `json:"project,omitempty"` // Channel conforms to Duck type Subscribable. // +optional Subscribable *eventingduck.Subscribable `json:"subscribable,omitempty"` }
ChannelSpec defines which subscribers have expressed interest in receiving events from this Channel. arguments for a Channel.
func (*ChannelSpec) DeepCopy ¶
func (in *ChannelSpec) DeepCopy() *ChannelSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ChannelSpec.
func (*ChannelSpec) DeepCopyInto ¶
func (in *ChannelSpec) DeepCopyInto(out *ChannelSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ChannelSpec) SetDefaults ¶
func (cs *ChannelSpec) SetDefaults(ctx context.Context)
func (*ChannelSpec) Validate ¶
func (cs *ChannelSpec) Validate(ctx context.Context) *apis.FieldError
type ChannelStatus ¶
type ChannelStatus struct { // inherits duck/v1beta1 Status, which currently provides: // * ObservedGeneration - the 'Generation' of the Service that was last processed by the controller. // * Conditions - the latest available observations of a resource's current state. duckv1beta1.Status `json:",inline"` // Channel is Addressable. It currently exposes the endpoint as a // fully-qualified DNS name which will distribute traffic over the // provided targets from inside the cluster. // // It generally has the form {channel}.{namespace}.svc.{cluster domain name} duckv1beta1.AddressStatus `json:",inline"` // Subscribers is populated with the statuses of each of the Channelable's subscribers. eventingduck.SubscribableStatus `json:",inline"` // ProjectID is the resolved project ID in use by the Channel. // +optional ProjectID string `json:"projectId,omitempty"` // TopicID is the created topic ID used by the Channel. // +optional TopicID string `json:"topicId,omitempty"` }
ChannelStatus represents the current state of a Channel.
func (*ChannelStatus) DeepCopy ¶
func (in *ChannelStatus) DeepCopy() *ChannelStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ChannelStatus.
func (*ChannelStatus) DeepCopyInto ¶
func (in *ChannelStatus) DeepCopyInto(out *ChannelStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ChannelStatus) GetCondition ¶
func (cs *ChannelStatus) GetCondition(t apis.ConditionType) *apis.Condition
GetCondition returns the condition currently associated with the given type, or nil.
func (*ChannelStatus) InitializeConditions ¶
func (cs *ChannelStatus) InitializeConditions()
InitializeConditions sets relevant unset conditions to Unknown state.
func (*ChannelStatus) IsReady ¶
func (cs *ChannelStatus) IsReady() bool
IsReady returns true if the resource is ready overall.
func (*ChannelStatus) MarkNoTopic ¶
func (cs *ChannelStatus) MarkNoTopic(reason, messageFormat string, messageA ...interface{})
MarkNoTopic sets the condition that signals there is not a topic for this Channel. This could be because of an error or the Channel is being deleted.
func (*ChannelStatus) MarkTopicNotOwned ¶
func (cs *ChannelStatus) MarkTopicNotOwned(messageFormat string, messageA ...interface{})
func (*ChannelStatus) MarkTopicOperating ¶
func (cs *ChannelStatus) MarkTopicOperating(reason, messageFormat string, messageA ...interface{})
MarkTopicOperating sets the condition that the topic is being created.
func (*ChannelStatus) MarkTopicReady ¶
func (cs *ChannelStatus) MarkTopicReady()
MarkTopicReady sets the condition that the topic has been created and ready.
func (*ChannelStatus) SetAddress ¶
func (cs *ChannelStatus) SetAddress(url *apis.URL)
SetAddress updates the Addressable status of the channel and propagates a url status to the Addressable status condition based on url.