utils

package
v0.0.0-...-8540d8e Latest Latest
Warning

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

Go to latest
Published: May 23, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	HttpScheme = "http"
)

Variables

This section is empty.

Functions

func Compare

func Compare(a, b []byte) bool

func GetClient

func GetClient() client.Client

GetClient default client created by the main operator's thread. It's safe to use since it's set when the operator main function runs.

func GetEnv

func GetEnv(key, fallback string) string

func GetOperatorIDAnnotation

func GetOperatorIDAnnotation(obj metav1.Object) string

GetOperatorIDAnnotation to safely get the operator id annotation value.

func IsOpenShift

func IsOpenShift() bool

IsOpenShift is a global flag that can be safely called across reconciliation cycles, defined at the controller manager start.

func OperatorID

func OperatorID() string

func Pbool

func Pbool(b bool) *bool

Pbool returns a pointer to a boolean

func Pint

func Pint(i int32) *int32

Pint returns a pointer to an int

func RemoveFileExtension

func RemoveFileExtension(fileName string) string

func RemoveKnownExtension

func RemoveKnownExtension(fileName, extension string) string

func SetClient

func SetClient(client client.Client)

SetClient is meant for internal use only. Don't call it!

func SetIsOpenShift

func SetIsOpenShift(cfg *rest.Config)

SetIsOpenShift sets the global flag isOpenShift by the controller manager. We don't need to keep fetching the API every reconciliation cycle that we need to know about the platform.

Types

type ApplicationPropertiesBuilder

type ApplicationPropertiesBuilder interface {
	WithInitialProperties(initialProperties *properties.Properties) ApplicationPropertiesBuilder
	WithImmutableProperties(immutableProperties *properties.Properties) ApplicationPropertiesBuilder
	WithDefaultManagedProperties(defaultManagedProperties *properties.Properties) ApplicationPropertiesBuilder
	BuildAsString() string
	Build() *properties.Properties
}

func NewApplicationPropertiesBuilder

func NewApplicationPropertiesBuilder() ApplicationPropertiesBuilder

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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