Documentation ¶
Index ¶
- Variables
- type AccountWatcher
- func (s *AccountWatcher) AccountsCanBeCreated() bool
- func (s *AccountWatcher) GetAccountCount() int
- func (s *AccountWatcher) GetLimit() int
- func (s *AccountWatcher) Start(log logr.Logger, stopCh context.Context, client client.Client, ...)
- func (s *AccountWatcher) UpdateTotalAccounts(log logr.Logger) error
- type AccountWatcherIface
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrAwsAccountLimitExceeded = errors.New("AccountLimitExceeded")
ErrAwsAccountLimitExceeded indicates the organization account limit has been reached.
View Source
var TotalAccountWatcher = &AccountWatcher{}
TotalAccountWatcher global var for TotalAccountWatcher
Functions ¶
This section is empty.
Types ¶
type AccountWatcher ¶
type AccountWatcher struct {
// contains filtered or unexported fields
}
func (*AccountWatcher) AccountsCanBeCreated ¶
func (s *AccountWatcher) AccountsCanBeCreated() bool
AccountsCanBeCreated returns whether we can create accounts or not
func (*AccountWatcher) GetAccountCount ¶
func (s *AccountWatcher) GetAccountCount() int
GetAccountCount returns the number of accounts that are currently recorded.
func (*AccountWatcher) GetLimit ¶
func (s *AccountWatcher) GetLimit() int
GetLimit returns the soft limit we have set in the configmap
func (*AccountWatcher) Start ¶
func (s *AccountWatcher) Start(log logr.Logger, stopCh context.Context, client client.Client, watchInterval time.Duration)
TotalAccountWatcher will trigger AwsLimitUpdate every `scanInternal` and only stop if the operator is killed or a message is sent on the stopCh
func (*AccountWatcher) UpdateTotalAccounts ¶
func (s *AccountWatcher) UpdateTotalAccounts(log logr.Logger) error
UpdateTotalAccounts will update the TotalAccountWatcher's total field
type AccountWatcherIface ¶
Click to show internal directories.
Click to hide internal directories.