utils

package
v0.11.1 Latest Latest
Warning

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

Go to latest
Published: Aug 21, 2026 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultE2ENamespace = "unstructured-controller-namespace"

DefaultE2ENamespace is the namespace used by e2e tests (must match test/e2e/main_test.go testNamespace).

Variables

This section is empty.

Functions

func FindDestinationKey added in v0.11.0

func FindDestinationKey(ctx context.Context, client *s3.Client, bucket, prefix, fileName string) (string, error)

FindDestinationKey lists objects under bucket/prefix and returns the .json key whose path contains fileName (e.g. "pdflatex-4-pages.pdf").

func GetControllerConfigResource added in v0.2.0

func GetControllerConfigResource() *v1alpha1.ControllerConfig

func GetUnstructuredDataPipelineResourceWithStage added in v0.8.0

func GetUnstructuredDataPipelineResourceWithStage(name, namespace string) v1alpha1.UnstructuredDataPipeline

GetUnstructuredDataPipelineResourceWithStage creates an UnstructuredDataPipeline CR for e2e tests

func RandomStringGenerator added in v0.8.0

func RandomStringGenerator(length int) string

RandomStringGenerator will return a random string of provided length

func WaitForResourceReady added in v0.5.0

func WaitForResourceReady(ctx context.Context, condition, crdName, resourceName, namespace string) error

WaitForResourceReady waits for a resource to be ready with a default 10m timeout.

func WaitForResourceReadyWithTimeout added in v0.10.0

func WaitForResourceReadyWithTimeout(
	ctx context.Context, condition, crdName, resourceName, namespace, timeout string,
) error

WaitForResourceReadyWithTimeout waits for a resource to be ready with a custom timeout.

Types

type S3ObjectMetadata added in v0.11.0

type S3ObjectMetadata struct {
	Key            string
	ChecksumSHA256 string
	LastModified   time.Time
}

func GetS3ObjectMetadata added in v0.11.0

func GetS3ObjectMetadata(ctx context.Context, client *s3.Client, bucket, key string) (S3ObjectMetadata, error)

GetS3ObjectMetadata HeadObjects an S3 key with checksum enabled.

func WaitForS3ObjectHashChange added in v0.11.0

func WaitForS3ObjectHashChange(
	ctx context.Context,
	client *s3.Client,
	bucket, key, hashBefore string,
) (S3ObjectMetadata, error)

Jump to

Keyboard shortcuts

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