openapi

package
v1.14.10 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2019 License: Apache-2.0, Apache-2.0 Imports: 29 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildSwagger

func BuildSwagger(crd *apiextensions.CustomResourceDefinition, version string) (*spec.Swagger, error)

BuildSwagger builds swagger for the given crd in the given version

func ConvertJSONSchemaPropsToOpenAPIv2Schema

func ConvertJSONSchemaPropsToOpenAPIv2Schema(in *apiextensions.JSONSchemaProps) (*spec.Schema, error)

ConvertJSONSchemaPropsToOpenAPIv2Schema converts our internal OpenAPI v3 schema (*apiextensions.JSONSchemaProps) to an OpenAPI v2 schema (*spec.Schema).

Types

type CRDCanonicalTypeNamer

type CRDCanonicalTypeNamer struct {
	// contains filtered or unexported fields
}

CRDCanonicalTypeNamer implements CanonicalTypeNamer interface for CRDs to seed kube-openapi canonical type name without Go types

func (*CRDCanonicalTypeNamer) OpenAPICanonicalTypeName

func (c *CRDCanonicalTypeNamer) OpenAPICanonicalTypeName() string

OpenAPICanonicalTypeName returns canonical type name for given CRD

type Controller

type Controller struct {
	// contains filtered or unexported fields
}

Controller watches CustomResourceDefinitions and publishes validation schema

func NewController

func NewController(crdInformer informers.CustomResourceDefinitionInformer) *Controller

NewController creates a new Controller with input CustomResourceDefinition informer

func (*Controller) Run

func (c *Controller) Run(staticSpec *spec.Swagger, openAPIService *handler.OpenAPIService, stopCh <-chan struct{})

Run sets openAPIAggregationManager and starts workers

Jump to

Keyboard shortcuts

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