Documentation
¶
Index ¶
- Variables
- func HasOperationalTag(tags []*crossplanerds.Tag) bool
- func MakeDeepCopyToOldDB(to *v1.StatusForOldDB, from *v1.Status)
- func Reconcile(r *DatabaseClaimReconciler, ctx context.Context, req ctrl.Request) (ctrl.Result, error)
- func ReplaceOrAddTag(tags []*crossplanerds.Tag, key string, value string) []*crossplanerds.Tag
- type DBClaimTags
- type DBTags
- type DatabaseClaimConfig
- type DatabaseClaimReconciler
- type ModeEnum
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // InfoLevel is used to set V level to 0 as suggested by official docs // https://github.com/kubernetes-sigs/controller-runtime/blob/main/TMP-LOGGING.md InfoLevel = 0 // DebugLevel is used to set V level to 1 as suggested by official docs // https://github.com/kubernetes-sigs/controller-runtime/blob/main/TMP-LOGGING.md DebugLevel = 1 // FIXME: remove references to private variables OperationalStatusTagKey string = "operational-status" OperationalStatusInactiveValue string = "inactive" OperationalStatusActiveValue string = "active" )
View Source
var ( ErrMaxNameLen = fmt.Errorf("dbclaim name is too long. max length is 44 characters") ErrInvalidDSNName = fmt.Errorf("dsn name must be: %s", v1.DSNKey) )
View Source
var (
ErrDoNotUpdateStatus = fmt.Errorf("do not update status for this error")
)
View Source
var ErrInvalidCredentialsPasswordMissing = fmt.Errorf("invalid_credentials_password_missing")
Functions ¶
func HasOperationalTag ¶
func HasOperationalTag(tags []*crossplanerds.Tag) bool
func MakeDeepCopyToOldDB ¶
func MakeDeepCopyToOldDB(to *v1.StatusForOldDB, from *v1.Status)
func ReplaceOrAddTag ¶
func ReplaceOrAddTag(tags []*crossplanerds.Tag, key string, value string) []*crossplanerds.Tag
Types ¶
type DBClaimTags ¶
type DBClaimTags []persistancev1.Tag
func (DBClaimTags) DBTags ¶
func (r DBClaimTags) DBTags() DBTags
func (DBClaimTags) Len ¶
func (r DBClaimTags) Len() int
implementation of sort interface to allow canolicalization of tags
func (DBClaimTags) Less ¶
func (r DBClaimTags) Less(i, j int) bool
func (DBClaimTags) Swap ¶
func (r DBClaimTags) Swap(i, j int)
type DBTags ¶
type DBTags []*crossplanerds.Tag
type DatabaseClaimConfig ¶
type DatabaseClaimReconciler ¶
type DatabaseClaimReconciler struct { client.Client Config *DatabaseClaimConfig // FIXME: give this a meaningful name Input *input // contains filtered or unexported fields }
DatabaseClaimReconciler reconciles a DatabaseClaim object
func (*DatabaseClaimReconciler) ManageOperationalTagging ¶
func (r *DatabaseClaimReconciler) ManageOperationalTagging(ctx context.Context, logr logr.Logger, dbInstanceName, dbParamGroupName string) (bool, error)
ManageOperationalTagging: Will update operational tags on old DBInstance, DBCluster, DBClusterParamGroup and DBParamGroup. It does not return error for DBCluster, DBClusterParamGroup and DBParamGroup if they fail to update tags. Such error is only logged, but not returned. In case of successful updation, It does not to verify whether those tags got updated.
Unlike other resources, It returns error just for DBinstance failling to update tags. It also verifies whether DBinstance got updated with the tag, and return the signal as boolean.
true: operational tag is updated and verfied. false: operational tag is updated but could not be verified yet.
Click to show internal directories.
Click to hide internal directories.