v1alpha1

package
v0.0.0-...-558fac8 Latest Latest
Warning

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

Go to latest
Published: Feb 25, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Overview

+k8s:deepcopy-gen=package +groupName=sources.muru.dev

Index

Constants

View Source
const (
	// GqlSourceConditionSinkProvided has status True when the GqlSource has been configured with a sink target.
	GqlSourceConditionSinkProvided apis.ConditionType = "SinkProvided"

	// GqlSourceConditionDeployed has status True when the GqlSource has had it's receive adapter deployment created.
	GqlSourceConditionDeployed apis.ConditionType = "Deployed"

	// GqlSourceConditionReady has status True when the GqlSource is ready to send events.
	GqlSourceConditionReady = apis.ConditionReady
)
View Source
const (
	EventType = "dev.knative.gql.event"
)

Variables

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

SchemeGroupVersion is group version used to register these objects

Functions

func GqlEventSource

func GqlEventSource(namespace, name string) string

GqlEventSource returns the GQL CloudEvent source.

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 GqlAuthSpec

type GqlAuthSpec struct {
	OIDC OIDCSpec `json:"oidc,omitempty"`
}

func (*GqlAuthSpec) DeepCopy

func (in *GqlAuthSpec) DeepCopy() *GqlAuthSpec

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

func (*GqlAuthSpec) DeepCopyInto

func (in *GqlAuthSpec) DeepCopyInto(out *GqlAuthSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type GqlSource

type GqlSource struct {
	metav1.TypeMeta `json:",inline"`
	// +optional
	metav1.ObjectMeta `json:"metadata,omitempty"`

	// Spec holds the desired state of the GqlSource (from the client).
	// +optional
	Spec GqlSourceSpec `json:"spec,omitempty"`

	// Status communicates the observed state of the GqlSource (from the controller).
	// +optional
	Status GqlSourceStatus `json:"status,omitempty"`
}

GqlSource is knative eventing source for graph ql subscription

func (*GqlSource) DeepCopy

func (in *GqlSource) DeepCopy() *GqlSource

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

func (*GqlSource) DeepCopyInto

func (in *GqlSource) DeepCopyInto(out *GqlSource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*GqlSource) DeepCopyObject

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

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*GqlSource) GetConditionSet

func (g *GqlSource) GetConditionSet() apis.ConditionSet

GetConditionSet retrieves the condition set for this resource. Implements the KRShaped interface.

func (*GqlSource) GetGroupVersionKind

func (g *GqlSource) GetGroupVersionKind() schema.GroupVersionKind

GetGroupVersionKind implements kmeta.OwnerRefable

func (*GqlSource) GetStatus

func (as *GqlSource) GetStatus() *duckv1.Status

GetStatus retrieves the status of the resource. Implements the KRShaped interface.

func (*GqlSource) SetDefaults

func (as *GqlSource) SetDefaults(ctx context.Context)

SetDefaults implements apis.Defaultable

func (*GqlSource) Validate

func (g *GqlSource) Validate(ctx context.Context) *apis.FieldError

Validate implements apis.Validatable

type GqlSourceList

type GqlSourceList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []GqlSource `json:"items"`
}

GqlSourceList is a list of GqlSource resources

func (*GqlSourceList) DeepCopy

func (in *GqlSourceList) DeepCopy() *GqlSourceList

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

func (*GqlSourceList) DeepCopyInto

func (in *GqlSourceList) DeepCopyInto(out *GqlSourceList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*GqlSourceList) DeepCopyObject

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

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type GqlSourceSpec

type GqlSourceSpec struct {
	// GqlServer holds the graphql endpoint
	GqlServer string `json:"gqlServer"`
	// Subscriptions holds the list of subscription queries that need to be tracked
	SubscriptionQueries []string `json:"subscriptionQueries"`
	// Sink holds the callable where cloud events need to be sent
	Sink *duckv1.Destination `json:"sink,omitempty"`
	// GqlAuthSpec embeds the security
	GqlAuthSpec `json:",inline"`
}

GqlSourceSpec holds the desired state of the GqlSource (from the client).

func (*GqlSourceSpec) DeepCopy

func (in *GqlSourceSpec) DeepCopy() *GqlSourceSpec

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

func (*GqlSourceSpec) DeepCopyInto

func (in *GqlSourceSpec) DeepCopyInto(out *GqlSourceSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*GqlSourceSpec) Validate

func (gs *GqlSourceSpec) Validate(ctx context.Context) *apis.FieldError

Validate implements apis.Validatable

type GqlSourceStatus

type GqlSourceStatus struct {
	// inherits duck/v1 SourceStatus, 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.
	// * SinkURI - the current active sink URI that has been configured for the
	//   Source.
	duckv1.SourceStatus `json:",inline"`
}

func (*GqlSourceStatus) DeepCopy

func (in *GqlSourceStatus) DeepCopy() *GqlSourceStatus

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

func (*GqlSourceStatus) DeepCopyInto

func (in *GqlSourceStatus) DeepCopyInto(out *GqlSourceStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*GqlSourceStatus) GetCondition

func (s *GqlSourceStatus) GetCondition(t apis.ConditionType) *apis.Condition

func (*GqlSourceStatus) GetTopLevelCondition

func (s *GqlSourceStatus) GetTopLevelCondition() *apis.Condition

func (*GqlSourceStatus) InitializeConditions

func (gs *GqlSourceStatus) InitializeConditions()

InitializeConditions sets the initial values to the conditions.

func (*GqlSourceStatus) IsReady

func (s *GqlSourceStatus) IsReady() bool

IsReady returns true if the resource is ready overall.

func (*GqlSourceStatus) MarkDeployed

func (s *GqlSourceStatus) MarkDeployed(d *appsv1.Deployment)

MarkDeployed sets the condition that the source has been deployed.

func (*GqlSourceStatus) MarkDeploying

func (s *GqlSourceStatus) MarkDeploying(reason, messageFormat string, messageA ...interface{})

MarkDeploying sets the condition that the source is deploying.

func (*GqlSourceStatus) MarkNoSink

func (gs *GqlSourceStatus) MarkNoSink(reason, messageFormat string, messageA ...interface{})

MarkNoSink sets the condition that the source does not have a sink configured.

func (*GqlSourceStatus) MarkNotDeployed

func (s *GqlSourceStatus) MarkNotDeployed(reason, messageFormat string, messageA ...interface{})

MarkNotDeployed sets the condition that the source has not been deployed.

func (*GqlSourceStatus) MarkSink

func (gs *GqlSourceStatus) MarkSink(uri *apis.URL)

MarkSink sets the condition that the source has a sink configured.

type OIDCSpec

type OIDCSpec struct {
	Enable bool `json:"enable,omitempty"`

	// TokenUrl is oidc token url
	// +optional
	TokenUrl SecretValueFromSource `json:"tokenUrl,omitempty"`
	// Key is the Kubernetes secret containing the client key.
	// +optional
	OIDCClient SecretValueFromSource `json:"oidcClient,omitempty"`
	// user to get oidc token.
	// +optional
	User SecretValueFromSource `json:"user,omitempty"`
	// password to get oidc token.
	// +optional
	Password SecretValueFromSource `json:"password,omitempty"`
}

func (*OIDCSpec) DeepCopy

func (in *OIDCSpec) DeepCopy() *OIDCSpec

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

func (*OIDCSpec) DeepCopyInto

func (in *OIDCSpec) DeepCopyInto(out *OIDCSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SecretValueFromSource

type SecretValueFromSource struct {
	// The Secret key to select from.
	SecretKeyRef *corev1.SecretKeySelector `json:"secretKeyRef,omitempty"`
}

SecretValueFromSource represents the source of a secret value

func (*SecretValueFromSource) DeepCopy

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

func (*SecretValueFromSource) DeepCopyInto

func (in *SecretValueFromSource) DeepCopyInto(out *SecretValueFromSource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

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