v1alpha1

package
v0.0.0-...-10d9840 Latest Latest
Warning

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

Go to latest
Published: May 3, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the simulation v1alpha1 API group +kubebuilder:object:generate=true +groupName=simulation.c930.net

Index

Constants

This section is empty.

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "simulation.c930.net", 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 DeploymentStatus

type DeploymentStatus struct {
	Replicas          int32 `json:"replicas,omitempty"`
	AvailableReplicas int32 `json:"availableReplicas,omitempty"`
	ReadyReplicas     int32 `json:"readyReplicas,omitempty"`
	UpToDateReplicas  int32 `json:"upToDateReplicas,omitempty"`
}

func (*DeploymentStatus) DeepCopy

func (in *DeploymentStatus) DeepCopy() *DeploymentStatus

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

func (*DeploymentStatus) DeepCopyInto

func (in *DeploymentStatus) DeepCopyInto(out *DeploymentStatus)

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

type NginxConfiguration

type NginxConfiguration struct {
	Replicas      *int32            `json:"replicas,omitempty"`
	ConfigMapData map[string]string `json:"configMapData,omitempty"`
	SecretData    map[string]string `json:"secretData,omitempty"`
	HTML          string            `json:"html,omitempty"`
}

func (*NginxConfiguration) DeepCopy

func (in *NginxConfiguration) DeepCopy() *NginxConfiguration

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

func (*NginxConfiguration) DeepCopyInto

func (in *NginxConfiguration) DeepCopyInto(out *NginxConfiguration)

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

type ResourceHashes

type ResourceHashes struct {
	ConfigMapHash string `json:"configMapHash,omitempty"`
	SecretHash    string `json:"secretHash,omitempty"`
	HtmlHash      string `json:"htmlHash,omitempty"`
}

func (*ResourceHashes) DeepCopy

func (in *ResourceHashes) DeepCopy() *ResourceHashes

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

func (*ResourceHashes) DeepCopyInto

func (in *ResourceHashes) DeepCopyInto(out *ResourceHashes)

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

type Workload

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

	Spec   WorkloadSpec   `json:"spec,omitempty"`
	Status WorkloadStatus `json:"status,omitempty"`
}

Workload is the Schema for the workloads API

func (*Workload) DeepCopy

func (in *Workload) DeepCopy() *Workload

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

func (*Workload) DeepCopyInto

func (in *Workload) DeepCopyInto(out *Workload)

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

func (*Workload) DeepCopyObject

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

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

type WorkloadList

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

WorkloadList contains a list of Workload

func (*WorkloadList) DeepCopy

func (in *WorkloadList) DeepCopy() *WorkloadList

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

func (*WorkloadList) DeepCopyInto

func (in *WorkloadList) DeepCopyInto(out *WorkloadList)

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

func (*WorkloadList) DeepCopyObject

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

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

type WorkloadSpec

type WorkloadSpec struct {

	// Type of simulation to perform: CPU, Memory, IO, Sleep
	SimulationType string `json:"simulationType,omitempty"`

	// Duration for the simulation or sleep (in seconds)
	Duration int `json:"duration,omitempty"`

	// Intensity of the workload for CPU or Memory or IO
	// This could be percentage for CPU, size in MB for Memory, and IO speed in MB/s
	Intensity int `json:"intensity,omitempty"`

	// Nginx configuration
	Nginx *NginxConfiguration `json:"nginx,omitempty"`
}

WorkloadSpec defines the desired state of Workload

func (*WorkloadSpec) DeepCopy

func (in *WorkloadSpec) DeepCopy() *WorkloadSpec

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

func (*WorkloadSpec) DeepCopyInto

func (in *WorkloadSpec) DeepCopyInto(out *WorkloadSpec)

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

type WorkloadStatus

type WorkloadStatus struct {
	// Reflects the current state of the simulation
	Executed bool `json:"executed,omitempty"`

	// StartTime is the timestamp representing the server time when this Workload started being reconciled by the operator
	StartTime string `json:"startTime,omitempty"`

	// EndTime is the timestamp representing the server time when this Workload ended being reconciled by the operator
	EndTime string `json:"endTime,omitempty"`

	// Conditions represent the latest available observations of an object's state
	Conditions []metav1.Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,1,rep,name=conditions"`

	// ResourceHashes represent the hash of the resources created by the operator
	ResourceHashes ResourceHashes `json:"resourceHashes,omitempty"`

	// ResourceStatus represent the status of the resources created by the operator
	DeploymentStatus DeploymentStatus `json:"resourceStatus,omitempty"`
}

WorkloadStatus defines the observed state of Workload

func (*WorkloadStatus) DeepCopy

func (in *WorkloadStatus) DeepCopy() *WorkloadStatus

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

func (*WorkloadStatus) DeepCopyInto

func (in *WorkloadStatus) DeepCopyInto(out *WorkloadStatus)

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