controllers

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2024 License: Apache-2.0 Imports: 37 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ErrMaxNameLen = Error("dbclaim name is too long. max length is 44 characters")
	// 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
)

Variables

This section is empty.

Functions

func GetDBName

func GetDBName(dbClaim *persistancev1.DatabaseClaim) string

func MakeDeepCopyToOldDB added in v1.0.1

func MakeDeepCopyToOldDB(to *persistancev1.StatusForOldDB, from *persistancev1.Status)

func ReplaceOrAddTag added in v1.0.2

func ReplaceOrAddTag(tags []*crossplanerds.Tag, key string, value string) []*crossplanerds.Tag

func SortTags

func SortTags(input []persistancev1.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 DatabaseClaimReconciler

type DatabaseClaimReconciler struct {
	client.Client
	Log                   logr.Logger
	Scheme                *runtime.Scheme
	Config                *viper.Viper
	MasterAuth            *rdsauth.MasterAuth
	DbIdentifierPrefix    string
	Mode                  ModeEnum
	Input                 *input
	Class                 string
	MetricsDepYamlPath    string
	MetricsConfigYamlPath string
}

DatabaseClaimReconciler reconciles a DatabaseClaim object

func (*DatabaseClaimReconciler) Reconcile

func (r *DatabaseClaimReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

func (*DatabaseClaimReconciler) SetupWithManager

func (r *DatabaseClaimReconciler) SetupWithManager(mgr ctrl.Manager) error

type DbRoleClaimReconciler

type DbRoleClaimReconciler struct {
	Class string
	client.Client
	Scheme   *runtime.Scheme
	Recorder record.EventRecorder
}

func (*DbRoleClaimReconciler) Reconcile

func (r *DbRoleClaimReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

func (*DbRoleClaimReconciler) SetupWithManager

func (r *DbRoleClaimReconciler) SetupWithManager(mgr ctrl.Manager) error

SetupWithManager sets up the controller with the Manager.

type Error

type Error string

func (Error) Error

func (e Error) Error() string

type ModeEnum

type ModeEnum int
const (
	M_NotSupported ModeEnum = iota
	M_UseExistingDB
	M_MigrateExistingToNewDB
	M_MigrationInProgress
	M_UseNewDB
	M_InitiateDBUpgrade
	M_UpgradeDBInProgress
	M_PostMigrationInProgress
)

Jump to

Keyboard shortcuts

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