v1alpha1

package
v0.9.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 17, 2019 License: Apache-2.0 Imports: 13 Imported by: 0

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

View Source
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"
)
View Source
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

View Source
var (
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
	AddToScheme   = SchemeBuilder.AddToScheme
)
View Source
var SchemeGroupVersion = schema.GroupVersion{Group: events.GroupName, Version: "v1alpha1"}

SchemeGroupVersion is group version used to register these objects

Functions

func Kind

func Kind(kind string) schema.GroupKind

Kind takes an unqualified kind and returns back a Group qualified GroupKind

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

func (in *Scheduler) DeepCopy() *Scheduler

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Scheduler.

func (*Scheduler) DeepCopyInto added in v0.9.0

func (in *Scheduler) DeepCopyInto(out *Scheduler)

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

func (in *Scheduler) DeepCopyObject() runtime.Object

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

func (s *Scheduler) SetDefaults(ctx context.Context)

func (*Scheduler) Validate added in v0.9.0

func (current *Scheduler) Validate(ctx context.Context) *apis.FieldError

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

func (in *Storage) DeepCopy() *Storage

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Storage.

func (*Storage) DeepCopyInto added in v0.8.1

func (in *Storage) DeepCopyInto(out *Storage)

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

func (in *Storage) DeepCopyObject() runtime.Object

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

func (s *Storage) SetDefaults(ctx context.Context)

func (*Storage) Validate added in v0.8.1

func (current *Storage) Validate(ctx context.Context) *apis.FieldError

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.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL