v1alpha1

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the standard v1alpha1 API group +kubebuilder:object:generate=true +groupName=standard.oam.dev

Index

Constants

This section is empty.

Variables

View Source
var (
	// SchemeGroupVersion is group version used to register these objects
	SchemeGroupVersion = schema.GroupVersion{Group: "standard.oam.dev", Version: "v1alpha1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

This section is empty.

Types

type Backend added in v0.0.4

type Backend struct {
	// Protocol means backend-protocol, HTTP, HTTPS, GRPC, GRPCS, AJP and FCGI, By default uses HTTP
	Protocol string `json:"protocol,omitempty"`
	// ReadTimeout used for setting read timeout duration for backend service, the unit is second.
	ReadTimeout int `json:"readTimeout,omitempty"`
	// SendTimeout used for setting send timeout duration for backend service, the unit is second.
	SendTimeout int `json:"sendTimeout,omitempty"`
	// Port points to backend service port.
	Port intstr.IntOrString `json:"port,omitempty"`
	// SelectLabels for backend service.
	SelectLabels map[string]string `json:"selectLabels,omitempty"`
}

Route will automatically discover podTemplate for Port and SelectLabels if they are not set. If Port and SelectLabels are already set, discovery won't work. If Port is not set, the first port discovered will be set. If SelectLabels are not set, all selectorLabels discovered will be set.

func (*Backend) DeepCopy added in v0.0.4

func (in *Backend) DeepCopy() *Backend

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

func (*Backend) DeepCopyInto added in v0.0.4

func (in *Backend) DeepCopyInto(out *Backend)

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

type Containerized

type Containerized struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   ContainerizedSpec   `json:"spec,omitempty"`
	Status ContainerizedStatus `json:"status,omitempty"`
}

Containerized is the Schema for the containerizeds API +kubebuilder:resource:categories={oam} +kubebuilder:subresource:status

func (*Containerized) DeepCopy

func (in *Containerized) DeepCopy() *Containerized

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

func (*Containerized) DeepCopyInto

func (in *Containerized) DeepCopyInto(out *Containerized)

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

func (*Containerized) DeepCopyObject

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

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

func (*Containerized) GetCondition

func (*Containerized) SetConditions

func (in *Containerized) SetConditions(c ...cpv1alpha1.Condition)

type ContainerizedList

type ContainerizedList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Containerized `json:"items"`
}

ContainerizedList contains a list of Containerized

func (*ContainerizedList) DeepCopy

func (in *ContainerizedList) DeepCopy() *ContainerizedList

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

func (*ContainerizedList) DeepCopyInto

func (in *ContainerizedList) DeepCopyInto(out *ContainerizedList)

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

func (*ContainerizedList) DeepCopyObject

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

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

type ContainerizedSpec

type ContainerizedSpec struct {
	// Replicas is the desired number of replicas of the given podSpec.
	// These are replicas in the sense that they are instantiations of the same podSpec.
	// If unspecified, defaults to 1.
	Replicas *int32 `json:"replicas"`

	// PodSpec describes the pods that will be created,
	// we omit the meta part as it will be exactly the same as the containerized
	PodSpec v1.PodSpec `json:"podSpec"`
}

ContainerizedSpec defines the desired state of Containerized

func (*ContainerizedSpec) DeepCopy

func (in *ContainerizedSpec) DeepCopy() *ContainerizedSpec

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

func (*ContainerizedSpec) DeepCopyInto

func (in *ContainerizedSpec) DeepCopyInto(out *ContainerizedSpec)

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

type ContainerizedStatus

type ContainerizedStatus struct {
	cpv1alpha1.ConditionedStatus `json:",inline"`

	// Resources managed by this workload.
	Resources []cpv1alpha1.TypedReference `json:"resources,omitempty"`
}

ContainerizedStatus defines the observed state of Containerized

func (*ContainerizedStatus) DeepCopy

func (in *ContainerizedStatus) DeepCopy() *ContainerizedStatus

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

func (*ContainerizedStatus) DeepCopyInto

func (in *ContainerizedStatus) DeepCopyInto(out *ContainerizedStatus)

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

type IssuerType added in v0.0.4

type IssuerType string
const (
	ClusterIssuer   IssuerType = "ClusterIssuer"
	NamespaceIssuer IssuerType = "Issuer"
)

type MetricsTrait

type MetricsTrait struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   MetricsTraitSpec   `json:"spec"`
	Status MetricsTraitStatus `json:"status,omitempty"`
}

MetricsTrait is the Schema for the metricstraits API +kubebuilder:resource:categories={oam} +kubebuilder:subresource:status

func (*MetricsTrait) DeepCopy

func (in *MetricsTrait) DeepCopy() *MetricsTrait

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

func (*MetricsTrait) DeepCopyInto

func (in *MetricsTrait) DeepCopyInto(out *MetricsTrait)

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

func (*MetricsTrait) DeepCopyObject

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

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

func (*MetricsTrait) GetCondition

func (*MetricsTrait) GetWorkloadReference

func (tr *MetricsTrait) GetWorkloadReference() runtimev1alpha1.TypedReference

GetWorkloadReference of this ManualScalerTrait.

func (*MetricsTrait) SetConditions

func (tr *MetricsTrait) SetConditions(c ...runtimev1alpha1.Condition)

func (*MetricsTrait) SetWorkloadReference

func (tr *MetricsTrait) SetWorkloadReference(r runtimev1alpha1.TypedReference)

SetWorkloadReference of this ManualScalerTrait.

type MetricsTraitList

type MetricsTraitList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []MetricsTrait `json:"items"`
}

MetricsTraitList contains a list of MetricsTrait

func (*MetricsTraitList) DeepCopy

func (in *MetricsTraitList) DeepCopy() *MetricsTraitList

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

func (*MetricsTraitList) DeepCopyInto

func (in *MetricsTraitList) DeepCopyInto(out *MetricsTraitList)

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

func (*MetricsTraitList) DeepCopyObject

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

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

type MetricsTraitSpec

type MetricsTraitSpec struct {
	// An endpoint to be monitored by a ServiceMonitor.
	ScrapeService ScapeServiceEndPoint `json:"scrapeService"`
	// WorkloadReference to the workload whose metrics needs to be exposed
	WorkloadReference runtimev1alpha1.TypedReference `json:"workloadRef,omitempty"`
}

MetricsTraitSpec defines the desired state of MetricsTrait

func (*MetricsTraitSpec) DeepCopy

func (in *MetricsTraitSpec) DeepCopy() *MetricsTraitSpec

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

func (*MetricsTraitSpec) DeepCopyInto

func (in *MetricsTraitSpec) DeepCopyInto(out *MetricsTraitSpec)

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

type MetricsTraitStatus

type MetricsTraitStatus struct {
	runtimev1alpha1.ConditionedStatus `json:",inline"`

	// ServiceMonitorNames managed by this trait
	ServiceMonitorNames []string `json:"serviceMonitorName,omitempty"`
}

MetricsTraitStatus defines the observed state of MetricsTrait

func (*MetricsTraitStatus) DeepCopy

func (in *MetricsTraitStatus) DeepCopy() *MetricsTraitStatus

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

func (*MetricsTraitStatus) DeepCopyInto

func (in *MetricsTraitStatus) DeepCopyInto(out *MetricsTraitStatus)

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

type Route added in v0.0.4

type Route struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   RouteSpec   `json:"spec,omitempty"`
	Status RouteStatus `json:"status,omitempty"`
}

+kubebuilder:object:root=true +kubebuilder:resource:categories={oam} +kubebuilder:subresource:status Route is the Schema for the routes API

func (*Route) DeepCopy added in v0.0.4

func (in *Route) DeepCopy() *Route

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

func (*Route) DeepCopyInto added in v0.0.4

func (in *Route) DeepCopyInto(out *Route)

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

func (*Route) DeepCopyObject added in v0.0.4

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

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

func (*Route) GetCondition added in v0.0.4

func (*Route) GetWorkloadReference added in v0.0.4

func (r *Route) GetWorkloadReference() runtimev1alpha1.TypedReference

GetWorkloadReference of this ManualScalerTrait.

func (*Route) SetConditions added in v0.0.4

func (r *Route) SetConditions(c ...runtimev1alpha1.Condition)

func (*Route) SetWorkloadReference added in v0.0.4

func (r *Route) SetWorkloadReference(rt runtimev1alpha1.TypedReference)

SetWorkloadReference of this ManualScalerTrait.

type RouteList added in v0.0.4

type RouteList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Route `json:"items"`
}

+kubebuilder:object:root=true RouteList contains a list of Route

func (*RouteList) DeepCopy added in v0.0.4

func (in *RouteList) DeepCopy() *RouteList

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

func (*RouteList) DeepCopyInto added in v0.0.4

func (in *RouteList) DeepCopyInto(out *RouteList)

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

func (*RouteList) DeepCopyObject added in v0.0.4

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

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

type RouteSpec added in v0.0.4

type RouteSpec struct {
	// WorkloadReference to the workload whose metrics needs to be exposed
	WorkloadReference runtimev1alpha1.TypedReference `json:"workloadRef,omitempty"`

	// Host is the host of the route
	Host string `json:"host"`

	// Path is location Path, default for "/"
	Path string `json:"path,omitempty"`

	// TLS indicate route trait will create SSL secret using cert-manager with specified issuer
	// If this is nil, route trait will use a selfsigned issuer
	TLS *TLS `json:"tls,omitempty"`

	// DefaultBackend uses serviceName
	DefaultBackend *v1beta1.IngressBackend `json:"defaultBackend,omitempty"`

	// RewriteTarget will rewrite request from Path to RewriteTarget path.
	RewriteTarget string `json:"rewriteTarget,omitempty"`

	// CustomHeaders pass a custom list of headers to the backend service.
	CustomHeaders map[string]string `json:"customHeaders,omitempty"`

	// Backend indicate how to connect backend service
	// If it's nil, will auto discovery
	Backend *Backend `json:"backend,omitempty"`
}

RouteSpec defines the desired state of Route

func (*RouteSpec) DeepCopy added in v0.0.4

func (in *RouteSpec) DeepCopy() *RouteSpec

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

func (*RouteSpec) DeepCopyInto added in v0.0.4

func (in *RouteSpec) DeepCopyInto(out *RouteSpec)

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

type RouteStatus added in v0.0.4

type RouteStatus struct {
	Ingress                           *runtimev1alpha1.TypedReference `json:"ingress,omitempty"`
	Service                           *runtimev1alpha1.TypedReference `json:"service,omitempty"`
	runtimev1alpha1.ConditionedStatus `json:",inline"`
}

RouteStatus defines the observed state of Route

func (*RouteStatus) DeepCopy added in v0.0.4

func (in *RouteStatus) DeepCopy() *RouteStatus

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

func (*RouteStatus) DeepCopyInto added in v0.0.4

func (in *RouteStatus) DeepCopyInto(out *RouteStatus)

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

type ScapeServiceEndPoint

type ScapeServiceEndPoint struct {
	// The format of the metrics data,
	// The default and only supported format is "prometheus" for now
	Format string `json:"format,omitempty"`
	// Number or name of the port to access on the pods targeted by the service.
	// When this field has value implies that we need to create a service for the workload
	// Mutually exclusive with port.
	TargetPort intstr.IntOrString `json:"port,omitempty"`
	// Route service traffic to pods with label keys and values matching this
	// The default is the labels in the workload
	// Mutually exclusive with port.
	TargetSelector map[string]string `json:"selector,omitempty"`
	// HTTP path to scrape for metrics.
	// default is /metrics
	// +optional
	Path string `json:"path,omitempty"`
	// Scheme at which metrics should be scraped
	// The default and only supported scheme is "http"
	// +optional
	Scheme string `json:"scheme,omitempty"`
	// The default is true
	// +optional
	Enabled *bool `json:"enabled,omitempty"`
}

ScapeServiceEndPoint defines a scrapeable endpoint serving Prometheus metrics.

func (*ScapeServiceEndPoint) DeepCopy

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

func (*ScapeServiceEndPoint) DeepCopyInto

func (in *ScapeServiceEndPoint) DeepCopyInto(out *ScapeServiceEndPoint)

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

type TLS added in v0.0.4

type TLS struct {
	IssuerName string `json:"issuerName,omitempty"`

	// Type indicate the issuer is ClusterIssuer or NamespaceIssuer
	Type IssuerType `json:"type,omitempty"`
}

func (*TLS) DeepCopy added in v0.0.4

func (in *TLS) DeepCopy() *TLS

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

func (*TLS) DeepCopyInto added in v0.0.4

func (in *TLS) DeepCopyInto(out *TLS)

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