Documentation
¶
Overview ¶
Copyright 2021.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2021.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
- Constants
- func GetConnectonCondition(inv *dbaasredhatcomv1alpha1.CrunchyBridgeConnection, condType string) *metav1.Condition
- func GetIInstanceCondition(inv *dbaasredhatcomv1alpha1.CrunchyBridgeInstance, condType string) *metav1.Condition
- func GetInventoryCondition(inv *dbaasredhatcomv1alpha1.CrunchyBridgeInventory, condType string) *metav1.Condition
- type CrunchyBridgeConnectionReconciler
- type CrunchyBridgeInstanceReconciler
- type CrunchyBridgeInventoryReconciler
- type DBaaSProviderReconciler
- type ObjectWithStatusConditions
Constants ¶
const ( SpecSynced string = "SpecSynced" BackendError string = "BackendError" AuthenticationError string = "AuthenticationError" InventoryNotFound string = "InventoryNotFound" SyncOK string = "SyncOK" ReadyForBinding string = "ReadyForBinding" ProvisionReady string = "ProvisionReady" Ready string = "Ready" NotFound string = "NotFound" InstanceSuccessMessage string = "Successfully created crunchy bridge cluster" SuccessMessage string = "Successfully listed crunchy bridge Inventories" SuccessConnection string = "Successfully retrieved the connection detail\n" )
const ( HOSTKEYNAME string = "host" PORTKEYNAME string = "port" DBKEYNAME string = "database" TYPEKEYNAME string = "type" DATABASESERVICETYPE string = "postgresql" PROVIDERVALUE = "Red Hat DBaaS / Crunchy Bridge" PROVIDERKEY = "provider" )
const ( PROVIDER = "Red Hat DBaaS / Crunchy Bridge" DISPLAYNAME = "Crunchy Bridge managed PostgreSQL" DISPLAYDESCRIPTION = "" /* 206-byte string literal not displayed */ INVENTORYDATAVALUE = "CrunchyBridgeInventory" CONNECTIONDATAVALUE = "CrunchyBridgeConnection" INSTANCEDATAVALUE = "CrunchyBridgeInstance" NAME = "crunchy-bridge-registration" ICONDATA = "" /* 21004-byte string literal not displayed */ MEDIATYPE = "image/png" KEYFIELDNAME = "publicApiKey" KEYFIELDDISPLAYNAME = "Public API Key" SECRETFIELDNAME = "privateApiSecret" SECRETFIELDDISPLAYNAME = "Private API Secret" RELATEDTOLABELNAME = "related-to" RELATEDTOLABELVALUE = "dbaas-operator" TYPELABELNAME = "type" TYPELABELVALUE = "dbaas-provider-registration" DBAASPROVIDERKIND = "DBaaSProvider" PROVISION_DOC_URL = "https://docs.crunchybridge.com/quickstart/provision" PROVISION_DESCRIPTION = "" /* 321-byte string literal not displayed */ )
const ( TEAM_ID = "team_id" PROVIDER_ID = "provider_id" REGION_ID = "region_id" CREATED_AT = "created_at" UPDATED_AT = "updated_at" MAJOR_VERSION = "major_version" STORAGE = "storage" CPU = "cpu" MEMORY = "memory" IS_HA = "is_ha" CLUSTER_NAME = "name" STATE = "state" )
const (
WatchInt = 10 * time.Second
)
Variables ¶
This section is empty.
Functions ¶
func GetConnectonCondition ¶
func GetConnectonCondition(inv *dbaasredhatcomv1alpha1.CrunchyBridgeConnection, condType string) *metav1.Condition
GetCondition return the condition with the passed condition type from the status object. If the condition is not already present, return nil
func GetIInstanceCondition ¶
func GetIInstanceCondition(inv *dbaasredhatcomv1alpha1.CrunchyBridgeInstance, condType string) *metav1.Condition
GetCondition return the condition with the passed condition type from the status object. If the condition is not already present, return nil
func GetInventoryCondition ¶
func GetInventoryCondition(inv *dbaasredhatcomv1alpha1.CrunchyBridgeInventory, condType string) *metav1.Condition
GetCondition return the condition with the passed condition type from the status object. If the condition is not already present, return nil
Types ¶
type CrunchyBridgeConnectionReconciler ¶
type CrunchyBridgeConnectionReconciler struct { client.Client Scheme *runtime.Scheme Clientset *kubernetes.Clientset APIBaseURL string }
CrunchyBridgeConnectionReconciler reconciles a CrunchyBridgeConnection object
func (*CrunchyBridgeConnectionReconciler) Reconcile ¶
func (r *CrunchyBridgeConnectionReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)
Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state. TODO(user): Modify the Reconcile function to compare the state specified by the CrunchyBridgeConnection object against the actual cluster state, and then perform operations to make the cluster state reflect the state specified by the user.
For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.8.3/pkg/reconcile
func (*CrunchyBridgeConnectionReconciler) SetupWithManager ¶
func (r *CrunchyBridgeConnectionReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager sets up the controller with the Manager.
type CrunchyBridgeInstanceReconciler ¶
type CrunchyBridgeInstanceReconciler struct { client.Client Scheme *runtime.Scheme APIBaseURL string }
CrunchyBridgeInstanceReconciler reconciles a CrunchyBridgeInstance object
func (*CrunchyBridgeInstanceReconciler) Reconcile ¶
func (r *CrunchyBridgeInstanceReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)
Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state. the CrunchyBridgeInstance object against the actual cluster state, and then perform operations to make the cluster state reflect the state specified by the user.
For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.9.2/pkg/reconcile
func (*CrunchyBridgeInstanceReconciler) SetupWithManager ¶
func (r *CrunchyBridgeInstanceReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager sets up the controller with the Manager.
type CrunchyBridgeInventoryReconciler ¶
type CrunchyBridgeInventoryReconciler struct { client.Client Scheme *runtime.Scheme APIBaseURL string Log logr.Logger }
CrunchyBridgeInventoryReconciler reconciles a CrunchyBridgeInventory object
func (*CrunchyBridgeInventoryReconciler) Reconcile ¶
func (r *CrunchyBridgeInventoryReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)
Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state. TODO(user): Modify the Reconcile function to compare the state specified by the CrunchyBridgeInventory object against the actual cluster state, and then perform operations to make the cluster state reflect the state specified by the user.
For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.8.3/pkg/reconcile
func (*CrunchyBridgeInventoryReconciler) SetupWithManager ¶
func (r *CrunchyBridgeInventoryReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager sets up the controller with the Manager.
type DBaaSProviderReconciler ¶
type DBaaSProviderReconciler struct { client.Client *runtime.Scheme Log logr.Logger Clientset *kubernetes.Clientset // contains filtered or unexported fields }
func (*DBaaSProviderReconciler) SetupWithManager ¶
func (r *DBaaSProviderReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager sets up the controller with the Manager.
type ObjectWithStatusConditions ¶
ObjectWithStatusConditions is an interface that describes kubernetes resource type structs with Status Conditions