util

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2020 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAccountFromNamespace

func GetAccountFromNamespace(namespace metav1.Object) string

GetAccountFromNamespace retrieves the account from a namespace meta

func InformerForResource

func InformerForResource(mgr manager.Manager, gvr schema.GroupVersionResource) (ctrlcache.Informer, error)

InformerForResource retrieves an informer for the given group version resource

func IsNamespaceInitializing

func IsNamespaceInitializing(namespace metav1.Object) bool

IsNamespaceInitializing checks if the given namespace is initializing

func ListerFuncForResourceFunc

func ListerFuncForResourceFunc(mgr manager.Manager) quota.ListerForResourceFunc

ListerFuncForResourceFunc knows how to provision a lister from an informer func. The lister returns errors until the informer has synced.

func Output

func Output(command string, args ...string) (string, error)

Output runs a specified command and pretty prints an possible error

func Run

func Run(command string, args ...string) error

Run runs a specified command and pretty prints an possible error

func StringsEqual

func StringsEqual(a []string, b []string) bool

StringsEqual checks if two string arrays are equal

Types

type LockFactory

type LockFactory interface {
	GetLock(string) sync.Locker
}

LockFactory is the interface to retrieve named locks from

func NewDefaultLockFactory

func NewDefaultLockFactory() LockFactory

NewDefaultLockFactory creates a new lock factory

Directories

Path Synopsis
ptr

Jump to

Keyboard shortcuts

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