Help us shape the future of Go! Take the 2026 Go Developer Survey

cockroachdb

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: May 7, 2019 License: MIT Imports: 28 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Add

func Add(mgr manager.Manager) error

Add creates a new CockroachDB Controller and adds it to the Manager. The Manager will set fields on the Controller and Start it when the Manager is Started.

func BatchJobForCockroachDB

func BatchJobForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

jobForCockroachDB returns a cockroachdb Job object

func ClientPodForCockroachDB

func ClientPodForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

clientPodForCockroachDB returns a cockroachdb ClientPod object

func ClusterRoleBindingForCockroachDB

func ClusterRoleBindingForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

clusterRoleBindingForCockroachDB returns a cockroachdb RoleBinding object

func ClusterRoleForCockroachDB

func ClusterRoleForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

clusterRoleForCockroachDB returns a cockroachdb ClusterRole object

func DashboardServiceForCockroachDB

func DashboardServiceForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

dashboardServiceForCockroachDB returns a cockroachdb DashboardService object

func PodDisruptionBudgetForCockroachDB

func PodDisruptionBudgetForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

podDisruptionBudgetForCockroachDB returns a cockroachdb PodDisruptionBudget object

func PublicServiceForCockroachDB

func PublicServiceForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

publicServiceForCockroachDB returns a cockroachdb Service object

func Register

func Register(h Name, f *Info) error

func RoleBindingForCockroachDB

func RoleBindingForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

roleBindingForCockroachDB returns a cockroachdb RoleBinding object

func RoleForCockroachDB

func RoleForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

roleForCockroachDB returns a cockroachdb Role object

func ServiceAccountForCockroachDB

func ServiceAccountForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

serviceAccountForCockroachDB returns a cockroachdb Service Account object

func ServiceForCockroachDB

func ServiceForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

serviceForCockroachDB returns a cockroachdb Service object

func StatefulSetForCockroachDB

func StatefulSetForCockroachDB(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

statefulSetForCockroachDB returns a cockroachdb StatefulSet object

Types

type Config

type Config struct {
	Handlers Map
	// contains filtered or unexported fields
}

type Info

type Info struct {
	Resource        ResourceType
	Reconcile       ReconcileType
	Object          runtime.Object
	Postfix         string
	SpecConditional string
	NoNamespace     bool
	SuppressStatus  bool
}

func Enumerate

func Enumerate() []Info

func NewInfo

func NewInfo(resource interface{}, recon interface{}, obj runtime.Object) *Info

type Map

type Map map[Name]*Info

type Name

type Name int
const (
	ClusterRoleHandler        Name = 400
	ClusterRoleBindingHandler Name = 500
)
const (
	RoleHandler        Name = 200
	RoleBindingHandler Name = 300
)
const (
	PublicServiceHandler Name = 600
	ServiceHandler       Name = 700
)
const BatchJobHandler Name = 1100
const ClientHandler Name = 1200
const DashboardHandler Name = 1400
const (
	PodDisruptionBudgetHandler Name = 800
)
const ServiceAccountHandler Name = 100
const StatefulSetHandler Name = 900
const UpdateStatusHandler Name = 1000

type ReconcileCockroachDB

type ReconcileCockroachDB struct {
	// contains filtered or unexported fields
}

ReconcileCockroachDB reconciles a CockroachDB object

func (*ReconcileCockroachDB) Reconcile

func (r *ReconcileCockroachDB) Reconcile(request reconcile.Request) (reconcile.Result, error)

Reconcile reads that state of the cluster for a CockroachDB object and makes changes based on the state read and what is in the CockroachDB.Spec a CockroachDB Deployment for each CockroachDB CR Note: The Controller will requeue the Request to be processed again if the returned error is non-nil or Result.Requeue is true, otherwise upon completion it will remove the work from the queue.

func (*ReconcileCockroachDB) UpdateStatus

func (r *ReconcileCockroachDB) UpdateStatus(db *dbv1alpha1.CockroachDB)

type ReconcileHandler

type ReconcileHandler interface {
	CallHandler(info *Info, db *dbv1alpha1.CockroachDB, r *ReconcileCockroachDB) (bool, reconcile.Result, error)
}

type ReconcileType

type ReconcileType func(info *Info, db *dbv1alpha1.CockroachDB, r *ReconcileCockroachDB) (bool, reconcile.Result, error)

func (ReconcileType) CallHandler

type ResourceHandler

type ResourceHandler interface {
	CallHandler(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}
}

type ResourceType

type ResourceType func(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

func (ResourceType) CallHandler

func (h ResourceType) CallHandler(r *ReconcileCockroachDB, m *dbv1alpha1.CockroachDB) interface{}

Jump to

Keyboard shortcuts

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