Documentation ¶
Index ¶
- Constants
- func CleanupNamespaces(virtCli kubecli.KubevirtClient, timeout time.Duration, ...) error
- func CreateNamespaceIfNotExist(virtCli kubecli.KubevirtClient, name, scenarioLabel, uuid string) error
- func CreateObject(virtCli kubecli.KubevirtClient, obj *unstructured.Unstructured) (*unstructured.Unstructured, error)
- func CreateObjectReplica(client kubecli.KubevirtClient, objSpec *config.ObjectSpec, objIdx *int, ...) (*unstructured.Unstructured, error)
- func CreateObjectReplicaSpec(obj *config.ObjectSpec, objIdx *int, uuid string) (*unstructured.Unstructured, error)
- func DeleteNObjectsInNamespaces(virtCli kubecli.KubevirtClient, resourceKind string, ...)
- func DeleteObject(virtCli kubecli.KubevirtClient, obj unstructured.Unstructured, ...)
- func GenerateObjectTemplateData(obj *config.ObjectSpec, replica int) map[string]interface{}
- func GetObjectResource(obj *unstructured.Unstructured) string
- func ListObjects(virtCli kubecli.KubevirtClient, resourceKind string, ...) (*unstructured.UnstructuredList, error)
- func RenderObject(templateData map[string]interface{}, objectSpec []byte) (*unstructured.Unstructured, error)
- func WaitForDeleteNamespaces(virtCli kubecli.KubevirtClient, timeout time.Duration, ...) error
Constants ¶
View Source
const ( Replica = "replica" Iteration = "iteration" UUID = "uuid" Namespace = "namespace" )
View Source
const ( VMIResource = "virtualmachineinstances" VMResource = "virtualmachines" VMIReplicaSetResource = "virtualmachineinstancereplicasets" )
Variables ¶
This section is empty.
Functions ¶
func CleanupNamespaces ¶
func CleanupNamespaces(virtCli kubecli.KubevirtClient, timeout time.Duration, listOpts *metav1.ListOptions) error
CleanupNamespaces deletes a collection of namespaces with the given selector
func CreateNamespaceIfNotExist ¶ added in v0.55.0
func CreateNamespaceIfNotExist(virtCli kubecli.KubevirtClient, name, scenarioLabel, uuid string) error
func CreateObject ¶
func CreateObject(virtCli kubecli.KubevirtClient, obj *unstructured.Unstructured) (*unstructured.Unstructured, error)
func CreateObjectReplica ¶ added in v0.55.0
func CreateObjectReplica(client kubecli.KubevirtClient, objSpec *config.ObjectSpec, objIdx *int, uuid string) (*unstructured.Unstructured, error)
func CreateObjectReplicaSpec ¶ added in v0.55.0
func CreateObjectReplicaSpec(obj *config.ObjectSpec, objIdx *int, uuid string) (*unstructured.Unstructured, error)
CreateObjectReplicaSpec returns the last created object to provies information for wait and delete the objects
func DeleteNObjectsInNamespaces ¶ added in v0.55.0
func DeleteNObjectsInNamespaces(virtCli kubecli.KubevirtClient, resourceKind string, listOpts *metav1.ListOptions, n int)
DeleteNObjectsInNamespaces deletes n objects in a set of namespace with a given selector. This is used to create churn in the steady state test
func DeleteObject ¶ added in v0.53.0
func DeleteObject(virtCli kubecli.KubevirtClient, obj unstructured.Unstructured, resourceKind string, gracePeriod int64)
func GenerateObjectTemplateData ¶
func GenerateObjectTemplateData(obj *config.ObjectSpec, replica int) map[string]interface{}
func GetObjectResource ¶
func GetObjectResource(obj *unstructured.Unstructured) string
GetObjectResource returns the resource type of an object The kubevirt API understand the resource type as plural
func ListObjects ¶ added in v0.53.0
func ListObjects(virtCli kubecli.KubevirtClient, resourceKind string, listOpts *metav1.ListOptions, namespace string) (*unstructured.UnstructuredList, error)
func RenderObject ¶ added in v0.53.0
func RenderObject(templateData map[string]interface{}, objectSpec []byte) (*unstructured.Unstructured, error)
RenderObject creates a Kubernetes Unstructured object from a template
func WaitForDeleteNamespaces ¶
func WaitForDeleteNamespaces(virtCli kubecli.KubevirtClient, timeout time.Duration, listOpts metav1.ListOptions) error
WaitForDeleteNamespaces waits to all namespaces with the given selector be deleted
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.