Documentation ¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the events v1alpha1 API group +k8s:openapi-gen=true +k8s:deepcopy-gen=package,register +k8s:conversion-gen=github.com/google/knative-gcp/pkg/apis/events +k8s:defaulter-gen=TypeMeta +groupName=events.cloud.run
Index ¶
- Constants
- Variables
- func Kind(kind string) schema.GroupKind
- func Resource(resource string) schema.GroupResource
- type Scheduler
- func (s *Scheduler) ConditionSet() *apis.ConditionSet
- func (in *Scheduler) DeepCopy() *Scheduler
- func (in *Scheduler) DeepCopyInto(out *Scheduler)
- func (in *Scheduler) DeepCopyObject() runtime.Object
- func (scheduler *Scheduler) GetGroupVersionKind() schema.GroupVersionKind
- func (s *Scheduler) PubSubSpec() *duckv1alpha1.PubSubSpec
- func (s *Scheduler) PubSubStatus() *duckv1alpha1.PubSubStatus
- func (s *Scheduler) SetDefaults(ctx context.Context)
- func (current *Scheduler) Validate(ctx context.Context) *apis.FieldError
- type SchedulerList
- type SchedulerSpec
- type SchedulerStatus
- func (in *SchedulerStatus) DeepCopy() *SchedulerStatus
- func (in *SchedulerStatus) DeepCopyInto(out *SchedulerStatus)
- func (s *SchedulerStatus) GetCondition(t apis.ConditionType) *apis.Condition
- func (s *SchedulerStatus) InitializeConditions()
- func (s *SchedulerStatus) IsReady() bool
- func (s *SchedulerStatus) MarkJobNotReady(reason, messageFormat string, messageA ...interface{})
- func (s *SchedulerStatus) MarkJobReady(jobName string)
- func (s *SchedulerStatus) MarkPullSubscriptionNotReady(reason, messageFormat string, messageA ...interface{})
- func (s *SchedulerStatus) MarkPullSubscriptionReady()
- func (s *SchedulerStatus) MarkTopicNotReady(reason, messageFormat string, messageA ...interface{})
- func (s *SchedulerStatus) MarkTopicReady(topicID, projectID string)
- type Storage
- func (s *Storage) ConditionSet() *apis.ConditionSet
- func (in *Storage) DeepCopy() *Storage
- func (in *Storage) DeepCopyInto(out *Storage)
- func (in *Storage) DeepCopyObject() runtime.Object
- func (storage *Storage) GetGroupVersionKind() schema.GroupVersionKind
- func (s *Storage) PubSubSpec() *duckv1alpha1.PubSubSpec
- func (s *Storage) PubSubStatus() *duckv1alpha1.PubSubStatus
- func (s *Storage) SetDefaults(ctx context.Context)
- func (current *Storage) Validate(ctx context.Context) *apis.FieldError
- type StorageList
- type StorageSpec
- type StorageStatus
- func (in *StorageStatus) DeepCopy() *StorageStatus
- func (in *StorageStatus) DeepCopyInto(out *StorageStatus)
- func (s *StorageStatus) GetCondition(t apis.ConditionType) *apis.Condition
- func (s *StorageStatus) InitializeConditions()
- func (s *StorageStatus) IsReady() bool
- func (s *StorageStatus) MarkNotificationNotReady(reason, messageFormat string, messageA ...interface{})
- func (s *StorageStatus) MarkNotificationReady()
- func (s *StorageStatus) MarkPullSubscriptionNotReady(reason, messageFormat string, messageA ...interface{})
- func (s *StorageStatus) MarkPullSubscriptionReady()
- func (s *StorageStatus) MarkTopicNotReady(reason, messageFormat string, messageA ...interface{})
- func (s *StorageStatus) MarkTopicReady()
Constants ¶
const ( // SchedulerConditionReady has status True when Scheduler is ready to send events. SchedulerConditionReady = apis.ConditionReady // JobReady has status True when Scheduler Job has been successfully created. JobReady apis.ConditionType = "JobReady" )
const ( // StorageConditionReady has status True when the Storage is ready to send events. StorageConditionReady = apis.ConditionReady // NotificationReady has status True when GCS has been configured properly to // send Notification events NotificationReady apis.ConditionType = "NotificationReady" )
Variables ¶
var ( SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) AddToScheme = SchemeBuilder.AddToScheme )
var SchemeGroupVersion = schema.GroupVersion{Group: events.GroupName, Version: "v1alpha1"}
SchemeGroupVersion is group version used to register these objects
var StorageCondSet = apis.NewLivingConditionSet( duckv1alpha1.PullSubscriptionReady, duckv1alpha1.TopicReady, NotificationReady)
Functions ¶
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group qualified GroupResource
Types ¶
type Scheduler ¶ added in v0.9.0
type Scheduler struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec SchedulerSpec `json:"spec"` Status SchedulerStatus `json:"status"` }
Scheduler is a specification for a Scheduler resource
func (*Scheduler) ConditionSet ¶ added in v0.9.0
func (s *Scheduler) ConditionSet() *apis.ConditionSet
ConditionSet returns the apis.ConditionSet of the embedding object
func (*Scheduler) DeepCopy ¶ added in v0.9.0
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Scheduler.
func (*Scheduler) DeepCopyInto ¶ added in v0.9.0
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Scheduler) DeepCopyObject ¶ added in v0.9.0
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*Scheduler) GetGroupVersionKind ¶ added in v0.9.0
func (scheduler *Scheduler) GetGroupVersionKind() schema.GroupVersionKind
func (*Scheduler) PubSubSpec ¶ added in v0.9.0
func (s *Scheduler) PubSubSpec() *duckv1alpha1.PubSubSpec
Methods for pubsubable interface PubSubSpec returns the PubSubSpec portion of the Spec.
func (*Scheduler) PubSubStatus ¶ added in v0.9.0
func (s *Scheduler) PubSubStatus() *duckv1alpha1.PubSubStatus
PubSubStatus returns the PubSubStatus portion of the Status.
func (*Scheduler) SetDefaults ¶ added in v0.9.0
type SchedulerList ¶ added in v0.9.0
type SchedulerList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata"` Items []Scheduler `json:"items"` }
SchedulerList is a list of Scheduler resources
func (*SchedulerList) DeepCopy ¶ added in v0.9.0
func (in *SchedulerList) DeepCopy() *SchedulerList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulerList.
func (*SchedulerList) DeepCopyInto ¶ added in v0.9.0
func (in *SchedulerList) DeepCopyInto(out *SchedulerList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SchedulerList) DeepCopyObject ¶ added in v0.9.0
func (in *SchedulerList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type SchedulerSpec ¶ added in v0.9.0
type SchedulerSpec struct { // This brings in the PubSub based Source Specs. Includes: // Sink, CloudEventOverrides, Secret, PubSubSecret, and Project duckv1alpha1.PubSubSpec // Location where to create the Job in. Location string `json:"location"` // Schedule in cron format, for example: "* * * * *" would be run // every minute. Schedule string `json:"schedule"` // What data to send Data string `json:"data"` }
SchedulerSpec is the spec for a Scheduler resource
func (*SchedulerSpec) DeepCopy ¶ added in v0.9.0
func (in *SchedulerSpec) DeepCopy() *SchedulerSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulerSpec.
func (*SchedulerSpec) DeepCopyInto ¶ added in v0.9.0
func (in *SchedulerSpec) DeepCopyInto(out *SchedulerSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SchedulerSpec) SetDefaults ¶ added in v0.9.0
func (s *SchedulerSpec) SetDefaults(ctx context.Context)
func (*SchedulerSpec) Validate ¶ added in v0.9.0
func (current *SchedulerSpec) Validate(ctx context.Context) *apis.FieldError
type SchedulerStatus ¶ added in v0.9.0
type SchedulerStatus struct { // This brings in our GCP PubSub based events importers // duck/v1beta1 Status, SinkURI, ProjectID, TopicID, and SubscriptionID duckv1alpha1.PubSubStatus // JobName is the name of the created scheduler Job on success. // +optional JobName string `json:"jobName,omitempty"` }
SchedulerStatus is the status for a Scheduler resource
func (*SchedulerStatus) DeepCopy ¶ added in v0.9.0
func (in *SchedulerStatus) DeepCopy() *SchedulerStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulerStatus.
func (*SchedulerStatus) DeepCopyInto ¶ added in v0.9.0
func (in *SchedulerStatus) DeepCopyInto(out *SchedulerStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SchedulerStatus) GetCondition ¶ added in v0.9.0
func (s *SchedulerStatus) GetCondition(t apis.ConditionType) *apis.Condition
GetCondition returns the condition currently associated with the given type, or nil.
func (*SchedulerStatus) InitializeConditions ¶ added in v0.9.0
func (s *SchedulerStatus) InitializeConditions()
InitializeConditions sets relevant unset conditions to Unknown state.
func (*SchedulerStatus) IsReady ¶ added in v0.9.0
func (s *SchedulerStatus) IsReady() bool
IsReady returns true if the resource is ready overall.
func (*SchedulerStatus) MarkJobNotReady ¶ added in v0.9.0
func (s *SchedulerStatus) MarkJobNotReady(reason, messageFormat string, messageA ...interface{})
MarkJobNotReady sets the condition that the Scheduler Job has not been successfully created.
func (*SchedulerStatus) MarkJobReady ¶ added in v0.9.0
func (s *SchedulerStatus) MarkJobReady(jobName string)
MarkJobReady sets the condition for Scheduler Job as Read and sets the Status.JobName to jobName
func (*SchedulerStatus) MarkPullSubscriptionNotReady ¶ added in v0.9.0
func (s *SchedulerStatus) MarkPullSubscriptionNotReady(reason, messageFormat string, messageA ...interface{})
MarkPullSubscriptionNotReady sets the condition that the underlying PullSubscription is not ready and why
func (*SchedulerStatus) MarkPullSubscriptionReady ¶ added in v0.9.0
func (s *SchedulerStatus) MarkPullSubscriptionReady()
MarkPullSubscriptionReady sets the condition that the underlying PullSubscription is ready
func (*SchedulerStatus) MarkTopicNotReady ¶ added in v0.9.0
func (s *SchedulerStatus) MarkTopicNotReady(reason, messageFormat string, messageA ...interface{})
MarkTopicNotReady sets the condition that the Topic was not created and why
func (*SchedulerStatus) MarkTopicReady ¶ added in v0.9.0
func (s *SchedulerStatus) MarkTopicReady(topicID, projectID string)
MarkTopicReady sets the condition that the underlying Topic was created successfully and sets the Status.TopicID to the specified topic and Status.ProjectID to the specified project.
type Storage ¶ added in v0.8.1
type Storage struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec StorageSpec `json:"spec"` Status StorageStatus `json:"status"` }
Storage is a specification for a Google Cloud Storage Source resource
func (*Storage) ConditionSet ¶ added in v0.9.0
func (s *Storage) ConditionSet() *apis.ConditionSet
ConditionSet returns the apis.ConditionSet of the embedding object
func (*Storage) DeepCopy ¶ added in v0.8.1
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Storage.
func (*Storage) DeepCopyInto ¶ added in v0.8.1
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Storage) DeepCopyObject ¶ added in v0.8.1
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*Storage) GetGroupVersionKind ¶ added in v0.8.1
func (storage *Storage) GetGroupVersionKind() schema.GroupVersionKind
func (*Storage) PubSubSpec ¶ added in v0.9.0
func (s *Storage) PubSubSpec() *duckv1alpha1.PubSubSpec
PubSubSpec returns the PubSubSpec portion of the Spec.
func (*Storage) PubSubStatus ¶ added in v0.9.0
func (s *Storage) PubSubStatus() *duckv1alpha1.PubSubStatus
PubSubStatus returns the PubSubStatus portion of the Status.
func (*Storage) SetDefaults ¶ added in v0.8.1
type StorageList ¶ added in v0.8.1
type StorageList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata"` Items []Storage `json:"items"` }
StorageList is a list of Storage resources
func (*StorageList) DeepCopy ¶ added in v0.8.1
func (in *StorageList) DeepCopy() *StorageList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StorageList.
func (*StorageList) DeepCopyInto ¶ added in v0.8.1
func (in *StorageList) DeepCopyInto(out *StorageList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StorageList) DeepCopyObject ¶ added in v0.8.1
func (in *StorageList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type StorageSpec ¶ added in v0.8.1
type StorageSpec struct { // This brings in the PubSub based Source Specs. Includes: // Sink, CloudEventOverrides, Secret, PubSubSecret, and Project duckv1alpha1.PubSubSpec // ServiceAccountName holds the name of the Kubernetes service account // as which the underlying K8s resources should be run. If unspecified // this will default to the "default" service account for the namespace // in which the GCS exists. // +optional ServiceAccountName string `json:"serviceAccountName,omitempty"` // Bucket to subscribe to. Bucket string `json:"bucket"` // EventTypes to subscribe to. If unspecified, then subscribe to all events. // +optional EventTypes []string `json:"eventTypes,omitempty"` // ObjectNamePrefix limits the notifications to objects with this prefix // +optional ObjectNamePrefix string `json:"objectNamePrefix,omitempty"` // PayloadFormat specifies the contents of the message payload. // See https://cloud.google.com/storage/docs/pubsub-notifications#payload. // +optional PayloadFormat string `json:"payloadFormat,omitempty"` }
StorageSpec is the spec for a Storage resource
func (*StorageSpec) DeepCopy ¶ added in v0.8.1
func (in *StorageSpec) DeepCopy() *StorageSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StorageSpec.
func (*StorageSpec) DeepCopyInto ¶ added in v0.8.1
func (in *StorageSpec) DeepCopyInto(out *StorageSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StorageSpec) SetDefaults ¶ added in v0.8.1
func (ss *StorageSpec) SetDefaults(ctx context.Context)
func (*StorageSpec) Validate ¶ added in v0.8.1
func (current *StorageSpec) Validate(ctx context.Context) *apis.FieldError
type StorageStatus ¶ added in v0.8.1
type StorageStatus struct { // This brings in our GCP PubSub based events importers // duck/v1beta1 Status, SinkURI, ProjectID, TopicID, and SubscriptionID duckv1alpha1.PubSubStatus // NotificationID is the ID that GCS identifies this notification as. // +optional NotificationID string `json:"notificationId,omitempty"` }
StorageStatus is the status for a GCS resource
func (*StorageStatus) DeepCopy ¶ added in v0.8.1
func (in *StorageStatus) DeepCopy() *StorageStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StorageStatus.
func (*StorageStatus) DeepCopyInto ¶ added in v0.8.1
func (in *StorageStatus) DeepCopyInto(out *StorageStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StorageStatus) GetCondition ¶ added in v0.8.1
func (s *StorageStatus) GetCondition(t apis.ConditionType) *apis.Condition
GetCondition returns the condition currently associated with the given type, or nil.
func (*StorageStatus) InitializeConditions ¶ added in v0.8.1
func (s *StorageStatus) InitializeConditions()
InitializeConditions sets relevant unset conditions to Unknown state.
func (*StorageStatus) IsReady ¶ added in v0.8.1
func (s *StorageStatus) IsReady() bool
IsReady returns true if the resource is ready overall.
func (*StorageStatus) MarkNotificationNotReady ¶ added in v0.9.0
func (s *StorageStatus) MarkNotificationNotReady(reason, messageFormat string, messageA ...interface{})
MarkNotificationNotReady sets the condition that the GCS has not been configured to send Notifications and why.
func (*StorageStatus) MarkNotificationReady ¶ added in v0.9.0
func (s *StorageStatus) MarkNotificationReady()
func (*StorageStatus) MarkPullSubscriptionNotReady ¶ added in v0.8.1
func (s *StorageStatus) MarkPullSubscriptionNotReady(reason, messageFormat string, messageA ...interface{})
MarkPullSubscriptionNotReady sets the condition that the underlying PullSubscription source is not ready and why.
func (*StorageStatus) MarkPullSubscriptionReady ¶ added in v0.8.1
func (s *StorageStatus) MarkPullSubscriptionReady()
MarkPullSubscriptionReady sets the condition that the underlying PubSub source is ready.
func (*StorageStatus) MarkTopicNotReady ¶ added in v0.9.0
func (s *StorageStatus) MarkTopicNotReady(reason, messageFormat string, messageA ...interface{})
MarkTopicNotReady sets the condition that the PubSub topic was not created and why.
func (*StorageStatus) MarkTopicReady ¶ added in v0.9.0
func (s *StorageStatus) MarkTopicReady()
MarkTopicReady sets the condition that the underlying PubSub topic was created successfully.