v1

package
v0.0.0-...-e0434a4 Latest Latest
Warning

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

Go to latest
Published: Jun 30, 2019 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ReportResourceSingular = "report"
	ReportResourcePlural   = "reports"
	ReportResourceVersion  = "v1"
	ReportResourceKind     = "Report"

	SummaryResourceSingular = "summary"
	SummaryResourcePlural   = "summaries"
	SummaryResourceVersion  = "v1"
	SummaryResourceKind     = "Summary"

	ReportResourceAPIVersion = reporter.GroupName + "/" + ReportResourceVersion

	RouteResourceName = ReportResourcePlural + "." + reporter.GroupName

	LayerComposition   = "composition"
	LayerFormation     = "formation"
	LayerOrchestration = "orchestration"
	LayerExecution     = "execution"
	LayerObject        = "object"
	LayerProvider      = "provider"
)

Variables

View Source
var (
	// SchemeBuilder needs to be exported as `SchemeBuilder` so
	// the code-generation can find it.
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
	// AddToScheme is exposed for API installation
	AddToScheme = SchemeBuilder.AddToScheme
)
View Source
var (
	ReportGvk = SchemeGroupVersion.WithKind(ReportResourceKind)
)
View Source
var SchemeGroupVersion = schema.GroupVersion{Group: reporter.GroupName, Version: ReportResourceVersion}

SchemeGroupVersion is group version used to register these objects.

Functions

func Kind

func Kind(kind string) schema.GroupKind

Kind takes an unqualified kind and returns a Group qualified GroupKind.

Types

type Event

type Event struct {
	Reason         string            `json:"reason,omitempty"`
	Message        string            `json:"message,omitempty"`
	FirstTimestamp meta_v1.Time      `json:"firstTimestamp,omitempty"`
	LastTimestamp  meta_v1.Time      `json:"lastTimestamp,omitempty"`
	Count          int32             `json:"count,omitempty"`
	Type           string            `json:"type,omitempty"`
	EventTime      meta_v1.MicroTime `json:"eventTime,omitempty"`
}

Event is a cut-down version of the real Kubernetes Event object For the user, it may be better to present something like:

https://github.com/kubernetes/kubernetes/blob/8c6fbd708c1012c397eb9c746a89c4fc907f02d4/pkg/printers/internalversion/describe.go#L3195

+k8s:deepcopy-gen=true

func ConvertV1EventToEvent

func ConvertV1EventToEvent(event *core_v1.Event) *Event

func (*Event) DeepCopy

func (in *Event) DeepCopy() *Event

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

func (*Event) DeepCopyInto

func (in *Event) DeepCopyInto(out *Event)

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

type NamespaceReport

type NamespaceReport struct {
	Composition   ReportLayer `json:"composition"`
	Formation     ReportLayer `json:"formation"`
	Orchestration ReportLayer `json:"orchestration"`
	Execution     ReportLayer `json:"execution"`
	Objects       ReportLayer `json:"objects"`
	Providers     ReportLayer `json:"providers"`
}

+k8s:deepcopy-gen=true

func (*NamespaceReport) DeepCopy

func (in *NamespaceReport) DeepCopy() *NamespaceReport

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

func (*NamespaceReport) DeepCopyInto

func (in *NamespaceReport) DeepCopyInto(out *NamespaceReport)

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

type Reference

type Reference struct {
	Name         string                 `json:"name"`
	Layer        string                 `json:"layer"`
	ResourceType string                 `json:"type,omitempty"`
	Attributes   map[string]interface{} `json:"attributes,omitempty"`
}

+k8s:deepcopy-gen=true

func (*Reference) DeepCopy

func (in *Reference) DeepCopy() *Reference

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

func (*Reference) DeepCopyInto

func (in *Reference) DeepCopyInto(out *Reference)

type Report

type Report struct {
	meta_v1.TypeMeta   `json:",inline"`
	meta_v1.ObjectMeta `json:"metadata,omitempty"`
	voyager.Location   `json:",inline"`
	Report             NamespaceReport `json:"report"`
}

+genclient +genclient:noStatus +k8s:deepcopy-gen=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*Report) DeepCopy

func (in *Report) DeepCopy() *Report

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

func (*Report) DeepCopyInto

func (in *Report) DeepCopyInto(out *Report)

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

func (*Report) DeepCopyObject

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

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

type ReportLayer

type ReportLayer struct {
	Resources []Resource `json:"resources"`
	Status    Status     `json:"status,omitempty"`
}

+k8s:deepcopy-gen=true

func (*ReportLayer) DeepCopy

func (in *ReportLayer) DeepCopy() *ReportLayer

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

func (*ReportLayer) DeepCopyInto

func (in *ReportLayer) DeepCopyInto(out *ReportLayer)

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

type ReportList

type ReportList struct {
	meta_v1.TypeMeta `json:",inline"`
	meta_v1.ListMeta `json:"metadata,omitempty"`

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

ReportList is a list of Reports. +k8s:deepcopy-gen=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*ReportList) DeepCopy

func (in *ReportList) DeepCopy() *ReportList

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

func (*ReportList) DeepCopyInto

func (in *ReportList) DeepCopyInto(out *ReportList)

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

func (*ReportList) DeepCopyObject

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

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

type Resource

type Resource struct {
	Name         string            `json:"name"`
	Version      string            `json:"version,omitempty"`
	ResourceType string            `json:"type,omitempty"`
	Properties   interface{}       `json:"properties,omitempty"`
	Spec         interface{}       `json:"spec,omitempty"`
	Status       Status            `json:"status,omitempty"`
	References   []Reference       `json:"references,omitempty"`
	UID          string            `json:"uid,omitempty"`
	Provider     *ResourceProvider `json:"provider,omitempty"`
	Events       []Event           `json:"events,omitempty"`
}

+k8s:deepcopy-gen=true

func (*Resource) DeepCopy

func (in *Resource) DeepCopy() *Resource

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

func (*Resource) DeepCopyInto

func (in *Resource) DeepCopyInto(out *Resource)

type ResourceProvider

type ResourceProvider struct {
	PlanID     string `json:"planId"`
	ClassID    string `json:"classId"`
	Namespaced bool   `json:"namespaced"`
}

type Status

type Status struct {
	Status    string        `json:"status,omitempty"`
	Reason    string        `json:"reason,omitempty"`
	Timestamp *meta_v1.Time `json:"timestamp,omitempty"`
}

+k8s:deepcopy-gen=true

func (*Status) DeepCopy

func (in *Status) DeepCopy() *Status

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

func (*Status) DeepCopyInto

func (in *Status) DeepCopyInto(out *Status)

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