Documentation
¶
Overview ¶
Package results provide types and methods used to assemble the results of deprecated objects
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Item ¶
type Item struct { Scope string `json:"scope,omitempty" yaml:"scope,omitempty"` ObjectName string `json:"objectname,omitempty" yaml:"objectname,omitempty"` Namespace string `json:"namespace,omitempty" yaml:"namespace,omitempty"` Location string `json:"location,omitempty" yaml:"location,omitempty"` }
Item definition of the Items inside a deprecated API
func ListObjects ¶
func ListObjects(items []unstructured.Unstructured) (deprecatedItems []Item)
ListObjects is a generic function that receives unstructured Kubernetes objects and convert to deprecatedItem to be used later in the results
type Result ¶
type Result struct { DeprecatedAPIs []ResultItem `json:"deprecated_apis" yaml:"deprecated_apis"` DeletedAPIs []ResultItem `json:"deleted_apis" yaml:"deleted_apis"` }
Result to show final user
type ResultItem ¶ added in v1.5.0
type ResultItem struct { Group string `json:"group,omitempty" yaml:"group,omitempty"` Kind string `json:"kind,omitempty" yaml:"kind,omitempty"` Version string `json:"version,omitempty" yaml:"version,omitempty"` Replacement *v1alpha1.GroupVersionKind `json:"replacement,omitempty" yaml:"replacement,omitempty"` // K8sVersion defines which k8s version this API was flagged K8sVersion string `json:"k8sversion,omitempty" yaml:"k8sversion,omitempty"` Description string `json:"description,omitempty" yaml:"description,omitempty"` Items []Item `json:"deleted_items,omitempty" yaml:"deleted_items,omitempty"` }
func CreateItem ¶ added in v1.5.0
func CreateItem(group, version, kind string, items []Item) ResultItem
Click to show internal directories.
Click to hide internal directories.