Documentation ¶
Index ¶
- type FactoryNotInitializedError
- type PooledFactory
- func (pf *PooledFactory) GetAWSClient() (bbAws.Client, error)
- func (pf *PooledFactory) GetCommandExecutor(cmd *cobra.Command, pod *coreV1.Pod, container string, command []string, ...) (remoteCommand.Executor, error)
- func (pf *PooledFactory) GetCommandWrapper(name string, args ...string) (*bbUtilApiWrappers.Command, error)
- func (pf *PooledFactory) GetConfigClient(command *cobra.Command) (*bbConfig.ConfigClient, error)
- func (pf *PooledFactory) GetCredentialHelper() (credentialhelper.CredentialHelper, error)
- func (pf *PooledFactory) GetFileSystemClient() (bbFileSystem.Client, error)
- func (pf *PooledFactory) GetGitLabClient() (bbGitLab.Client, error)
- func (pf *PooledFactory) GetHelmClient(cmd *cobra.Command, namespace string) (helm.Client, error)
- func (pf *PooledFactory) GetIOStream() (*genericIOOptions.IOStreams, error)
- func (pf *PooledFactory) GetIronBankClient() (ironbank.Client, error)
- func (pf *PooledFactory) GetIstioClientSet(cfg *rest.Config) (bbUtilApiWrappers.IstioClientset, error)
- func (pf *PooledFactory) GetK8sClientset(cmd *cobra.Command) (kubernetes.Interface, error)
- func (pf *PooledFactory) GetK8sDynamicClient(cmd *cobra.Command) (dynamic.Interface, error)
- func (pf *PooledFactory) GetLoggingClient() (bbLog.Client, error)
- func (pf *PooledFactory) GetLoggingClientWithLogger(logger *slog.Logger) (bbLog.Client, error)
- func (pf *PooledFactory) GetOutputClient(cmd *cobra.Command) (bbOutput.Client, error)
- func (pf *PooledFactory) GetPipe() (commonInterfaces.FileLike, commonInterfaces.FileLike, error)
- func (pf *PooledFactory) GetRestConfig(cmd *cobra.Command) (*rest.Config, error)
- func (pf *PooledFactory) GetRuntimeClient(scheme *runtime.Scheme) (runtimeClient.Client, error)
- func (pf *PooledFactory) GetViper() (*viper.Viper, error)
- func (pf *PooledFactory) SetUnderlyingFactory(factory bbUtil.Factory)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FactoryNotInitializedError ¶
type FactoryNotInitializedError struct{}
FactoryNotInitializedError is returned when the factory is not initialized
func (FactoryNotInitializedError) Error ¶
func (e FactoryNotInitializedError) Error() string
Error returns the error message
type PooledFactory ¶
type PooledFactory struct {
// contains filtered or unexported fields
}
Factory is an interface for creating clients
func NewPooledFactory ¶
func NewPooledFactory() *PooledFactory
NewPooledFactory returns a new pooled factory
func (*PooledFactory) GetAWSClient ¶
func (pf *PooledFactory) GetAWSClient() (bbAws.Client, error)
GetAWSClient returns the AWS client
Pooled by client (singleton)
func (*PooledFactory) GetCommandExecutor ¶
func (pf *PooledFactory) GetCommandExecutor( cmd *cobra.Command, pod *coreV1.Pod, container string, command []string, stdout io.Writer, stderr io.Writer, ) (remoteCommand.Executor, error)
GetCommandExecutor returns the command executor
Not pooled (pass-through)
func (*PooledFactory) GetCommandWrapper ¶
func (pf *PooledFactory) GetCommandWrapper( name string, args ...string, ) (*bbUtilApiWrappers.Command, error)
GetCommandWrapper returns the command wrapper
Not pooled (pass-through)
func (*PooledFactory) GetConfigClient ¶
func (pf *PooledFactory) GetConfigClient(command *cobra.Command) (*bbConfig.ConfigClient, error)
GetConfigClient returns the config client
Not pooled (pass-through)
func (*PooledFactory) GetCredentialHelper ¶
func (pf *PooledFactory) GetCredentialHelper() (credentialhelper.CredentialHelper, error)
GetCredentialHelper returns the credential helper
Pooled by helper (singleton)
func (*PooledFactory) GetFileSystemClient ¶
func (pf *PooledFactory) GetFileSystemClient() (bbFileSystem.Client, error)
GetFileSystemClient returns a client for the underlying file system
func (*PooledFactory) GetGitLabClient ¶
func (pf *PooledFactory) GetGitLabClient() (bbGitLab.Client, error)
GetGitLabClient returns the GitLab client
Pooled by client (singleton)
func (*PooledFactory) GetHelmClient ¶
GetHelmClient returns the Helm client
Pooled by namespace, we assume cmd never changes
func (*PooledFactory) GetIOStream ¶
func (pf *PooledFactory) GetIOStream() (*genericIOOptions.IOStreams, error)
GetIOStream returns the IO stream
Pooled by instance (singleton)
func (*PooledFactory) GetIronBankClient ¶
func (pf *PooledFactory) GetIronBankClient() (ironbank.Client, error)
GetIronBankClient returns a client for interacting with IronBank
func (*PooledFactory) GetIstioClientSet ¶
func (pf *PooledFactory) GetIstioClientSet( cfg *rest.Config, ) (bbUtilApiWrappers.IstioClientset, error)
GetIstioClientSet returns the Istio clientset
Pooled by cfg
func (*PooledFactory) GetK8sClientset ¶
func (pf *PooledFactory) GetK8sClientset(cmd *cobra.Command) (kubernetes.Interface, error)
GetK8sClientset returns the Kubernetes clientset
Pooled by client (singleton), we assume cmd never changes
func (*PooledFactory) GetK8sDynamicClient ¶
GetK8sDynamicClient returns the Kubernetes dynamic client
Pooled by client (singleton), we assume cmd never changes
func (*PooledFactory) GetLoggingClient ¶
func (pf *PooledFactory) GetLoggingClient() (bbLog.Client, error)
GetLoggingClient returns the logging client
Pooled by logger (see GetLoggingClientWithLogger)
func (*PooledFactory) GetLoggingClientWithLogger ¶
GetLoggingClientWithLogger returns the logging client with a logger
Pooled by logger
func (*PooledFactory) GetOutputClient ¶
GetOutputClient returns the output client
Pooled by client (singleton), we assume cmd never changes
func (*PooledFactory) GetPipe ¶
func (pf *PooledFactory) GetPipe() (commonInterfaces.FileLike, commonInterfaces.FileLike, error)
CreatePipe initializes the pipe if not already created
func (*PooledFactory) GetRestConfig ¶
GetRestConfig returns the REST config
Pooled by config (singleton), we assume cmd never changes
func (*PooledFactory) GetRuntimeClient ¶
func (pf *PooledFactory) GetRuntimeClient(scheme *runtime.Scheme) (runtimeClient.Client, error)
GetRuntimeClient returns the runtime client
Pooled by scheme
func (*PooledFactory) GetViper ¶
func (pf *PooledFactory) GetViper() (*viper.Viper, error)
GetViper returns the Viper
Pooled by client (singleton)
func (*PooledFactory) SetUnderlyingFactory ¶
func (pf *PooledFactory) SetUnderlyingFactory(factory bbUtil.Factory)
SetUnderlyingFactory sets the underlying factory