v1alpha1

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: May 31, 2025 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the observability v1alpha1 API group +kubebuilder:object:generate=true +groupName=observability.aggregator.io

Index

Constants

This section is empty.

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "observability.aggregator.io", Version: "v1alpha1"}

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

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

Functions

This section is empty.

Types

type APIInfo

type APIInfo struct {
	// Name is the name of the API (usually same as deployment name)
	Name string `json:"name"`

	// URL is the full URL where the OpenAPI spec can be accessed
	URL string `json:"url"`

	// LastUpdated is when the spec was last successfully collected
	LastUpdated string `json:"lastUpdated"`

	// Error is set if there was an error collecting the spec
	Error string `json:"error,omitempty"`

	// ResourceType is the type of the kubernetes resource (Deployment)
	ResourceType string `json:"resourceType"`

	// ResourceName is the name of the kubernetes resource
	ResourceName string `json:"resourceName"`

	// Namespace is the namespace of the kubernetes resource
	Namespace string `json:"namespace"`

	// Path is the OpenAPI spec path for this service
	Path string `json:"path"`

	// Port is the port for this service's OpenAPI spec
	Port string `json:"port"`

	// Annotations stores relevant annotations from the resource
	Annotations map[string]string `json:"annotations,omitempty"`
}

APIInfo contains information about a collected OpenAPI spec

func (*APIInfo) DeepCopy

func (in *APIInfo) DeepCopy() *APIInfo

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

func (*APIInfo) DeepCopyInto

func (in *APIInfo) DeepCopyInto(out *APIInfo)

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

type OpenAPIAggregator

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

	Spec   OpenAPIAggregatorSpec   `json:"spec,omitempty"`
	Status OpenAPIAggregatorStatus `json:"status,omitempty"`
}

OpenAPIAggregator is the Schema for the openapiaggregators API

func (*OpenAPIAggregator) DeepCopy

func (in *OpenAPIAggregator) DeepCopy() *OpenAPIAggregator

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

func (*OpenAPIAggregator) DeepCopyInto

func (in *OpenAPIAggregator) DeepCopyInto(out *OpenAPIAggregator)

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

func (*OpenAPIAggregator) DeepCopyObject

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

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

type OpenAPIAggregatorList

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

OpenAPIAggregatorList contains a list of OpenAPIAggregator

func (*OpenAPIAggregatorList) DeepCopy

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

func (*OpenAPIAggregatorList) DeepCopyInto

func (in *OpenAPIAggregatorList) DeepCopyInto(out *OpenAPIAggregatorList)

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

func (*OpenAPIAggregatorList) DeepCopyObject

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

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

type OpenAPIAggregatorSpec

type OpenAPIAggregatorSpec struct {
	// LabelSelector selects target deployments to collect OpenAPI specs from
	LabelSelector map[string]string `json:"labelSelector,omitempty"`

	// DefaultPath is the default path for OpenAPI documentation
	// +kubebuilder:default="/v2/api-docs"
	DefaultPath string `json:"defaultPath,omitempty"`

	// DefaultPort is the default port for OpenAPI documentation
	// +kubebuilder:default="8080"
	DefaultPort string `json:"defaultPort,omitempty"`

	// SwaggerAnnotation is the annotation key that indicates if the Service should be included
	// +kubebuilder:default="openapi.aggregator.io/swagger"
	SwaggerAnnotation string `json:"swaggerAnnotation,omitempty"`

	// PathAnnotation is the annotation key for OpenAPI path
	// +kubebuilder:default="openapi.aggregator.io/path"
	PathAnnotation string `json:"pathAnnotation,omitempty"`

	// PortAnnotation is the annotation key for OpenAPI port
	// +kubebuilder:default="openapi.aggregator.io/port"
	PortAnnotation string `json:"portAnnotation,omitempty"`
}

OpenAPIAggregatorSpec defines the desired state of OpenAPIAggregator

func (*OpenAPIAggregatorSpec) DeepCopy

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

func (*OpenAPIAggregatorSpec) DeepCopyInto

func (in *OpenAPIAggregatorSpec) DeepCopyInto(out *OpenAPIAggregatorSpec)

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

type OpenAPIAggregatorStatus

type OpenAPIAggregatorStatus struct {
	// CollectedAPIs contains information about the OpenAPI specs that have been collected
	CollectedAPIs []APIInfo `json:"collectedAPIs,omitempty"`
}

OpenAPIAggregatorStatus defines the observed state of OpenAPIAggregator

func (*OpenAPIAggregatorStatus) DeepCopy

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

func (*OpenAPIAggregatorStatus) DeepCopyInto

func (in *OpenAPIAggregatorStatus) DeepCopyInto(out *OpenAPIAggregatorStatus)

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