From 8033e31bd9329ce57d304ce89e22e30e8a932fba Mon Sep 17 00:00:00 2001 From: lgtm <1gtm@users.noreply.github.com> Date: Wed, 12 Oct 2022 01:18:29 -0700 Subject: [PATCH] Prepare for release v0.29.0-rc.0 (#684) ProductLine: KubeDB Release: v2022.10.12-rc.0 Release-tracker: https://github.com/kubedb/CHANGELOG/pull/57 Signed-off-by: 1gtm <1gtm@appscode.com> Signed-off-by: 1gtm <1gtm@appscode.com> --- go.mod | 2 +- go.sum | 4 +-- .../autoscaling/v1alpha1/openapi_generated.go | 27 +--------------- .../v1alpha1/redis_sentinel_types.go | 5 --- .../v1alpha1/redis_sentinel_webhook.go | 4 --- .../v1alpha1/zz_generated.deepcopy.go | 26 --------------- .../kubedb/v1alpha2/perconaxtradb_helpers.go | 32 ++++++++++++++----- .../apis/postgres/v1alpha1/publisher_types.go | 4 +++ .../postgres/v1alpha1/subscriber_types.go | 4 +++ ...g.kubedb.com_redissentinelautoscalers.yaml | 19 ----------- vendor/modules.txt | 2 +- 11 files changed, 37 insertions(+), 92 deletions(-) diff --git a/go.mod b/go.mod index 53c574b98..0ef878fd3 100644 --- a/go.mod +++ b/go.mod @@ -22,7 +22,7 @@ require ( kmodules.xyz/client-go v0.25.6 kmodules.xyz/custom-resources v0.25.1 kmodules.xyz/monitoring-agent-api v0.25.0 - kubedb.dev/apimachinery v0.28.4-0.20221007091615-35e1d5e5bcb6 + kubedb.dev/apimachinery v0.29.0-rc.0 stash.appscode.dev/apimachinery v0.23.0 ) diff --git a/go.sum b/go.sum index e871eb93f..3d9d12d31 100644 --- a/go.sum +++ b/go.sum @@ -997,8 +997,8 @@ kmodules.xyz/offshoot-api v0.25.0 h1:Svq9da/+sg5afOjpgo9vx2J/Lu90Mo0aFxkdQmgKnGI kmodules.xyz/offshoot-api v0.25.0/go.mod h1:ysEBn7LJuT3+s8ynAQA/OG0BSsJugXa6KGtDLMRjlKo= kmodules.xyz/prober v0.25.0 h1:R5uRLHJEvEtEoogj+vaTAob0Btph6+PX5IlS6hPh8PA= kmodules.xyz/prober v0.25.0/go.mod h1:z4RTnjaajNQa/vPltsiOnO3xI716I/ziD2ac2Exm+1M= -kubedb.dev/apimachinery v0.28.4-0.20221007091615-35e1d5e5bcb6 h1:zrlfmcSezG2O94V8tc7E8GpWZvJEU9wMrjLauaD1Wfw= -kubedb.dev/apimachinery v0.28.4-0.20221007091615-35e1d5e5bcb6/go.mod h1:8/kV/429eH4DlQ24vwRaxkf1mMhN6FL/nvuPEJt2CYc= +kubedb.dev/apimachinery v0.29.0-rc.0 h1:mJek0RJaPkgBGue4h4BQjxQLX2wToX4RtxG5wnJSlnk= +kubedb.dev/apimachinery v0.29.0-rc.0/go.mod h1:8/kV/429eH4DlQ24vwRaxkf1mMhN6FL/nvuPEJt2CYc= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/openapi_generated.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/openapi_generated.go index 74a9ce70d..a8f87d4da 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/openapi_generated.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/openapi_generated.go @@ -504,7 +504,6 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelComputeAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelComputeAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelOpsRequestOptions(ref), - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelStorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_RedisStorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_StorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.VPAStatus": schema_apimachinery_apis_autoscaling_v1alpha1_VPAStatus(ref), @@ -24166,17 +24165,12 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelAutoscalerSpec(r Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelComputeAutoscalerSpec"), }, }, - "storage": { - SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelStorageAutoscalerSpec"), - }, - }, }, Required: []string{"databaseRef"}, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelOpsRequestOptions", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelStorageAutoscalerSpec"}, + "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelOpsRequestOptions"}, } } @@ -24226,25 +24220,6 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelOpsRequestOption } } -func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "sentinel": { - SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"}, - } -} - func schema_apimachinery_apis_autoscaling_v1alpha1_RedisStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_types.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_types.go index c92bf9358..839982454 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_types.go @@ -66,17 +66,12 @@ type RedisSentinelAutoscalerSpec struct { OpsRequestOptions *RedisSentinelOpsRequestOptions `json:"opsRequestOptions,omitempty"` Compute *RedisSentinelComputeAutoscalerSpec `json:"compute,omitempty"` - Storage *RedisSentinelStorageAutoscalerSpec `json:"storage,omitempty"` } type RedisSentinelComputeAutoscalerSpec struct { Sentinel *ComputeAutoscalerSpec `json:"sentinel,omitempty"` } -type RedisSentinelStorageAutoscalerSpec struct { - Sentinel *StorageAutoscalerSpec `json:"sentinel,omitempty"` -} - type RedisSentinelOpsRequestOptions struct { // Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure. Timeout *metav1.Duration `json:"timeout,omitempty"` diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_webhook.go index 7626909cc..5e530f24a 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_webhook.go @@ -50,10 +50,6 @@ func (in *RedisSentinelAutoscaler) Default() { func (in *RedisSentinelAutoscaler) setDefaults() { in.setOpsReqOptsDefaults() - if in.Spec.Storage != nil { - setDefaultStorageValues(in.Spec.Storage.Sentinel) - } - if in.Spec.Compute != nil { setDefaultComputeValues(in.Spec.Compute.Sentinel) } diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zz_generated.deepcopy.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zz_generated.deepcopy.go index 595d8c257..c8ee28d64 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zz_generated.deepcopy.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zz_generated.deepcopy.go @@ -2350,11 +2350,6 @@ func (in *RedisSentinelAutoscalerSpec) DeepCopyInto(out *RedisSentinelAutoscaler *out = new(RedisSentinelComputeAutoscalerSpec) (*in).DeepCopyInto(*out) } - if in.Storage != nil { - in, out := &in.Storage, &out.Storage - *out = new(RedisSentinelStorageAutoscalerSpec) - (*in).DeepCopyInto(*out) - } return } @@ -2410,27 +2405,6 @@ func (in *RedisSentinelOpsRequestOptions) DeepCopy() *RedisSentinelOpsRequestOpt return out } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *RedisSentinelStorageAutoscalerSpec) DeepCopyInto(out *RedisSentinelStorageAutoscalerSpec) { - *out = *in - if in.Sentinel != nil { - in, out := &in.Sentinel, &out.Sentinel - *out = new(StorageAutoscalerSpec) - (*in).DeepCopyInto(*out) - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisSentinelStorageAutoscalerSpec. -func (in *RedisSentinelStorageAutoscalerSpec) DeepCopy() *RedisSentinelStorageAutoscalerSpec { - if in == nil { - return nil - } - out := new(RedisSentinelStorageAutoscalerSpec) - in.DeepCopyInto(out) - return out -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *RedisStorageAutoscalerSpec) DeepCopyInto(out *RedisStorageAutoscalerSpec) { *out = *in diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/perconaxtradb_helpers.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/perconaxtradb_helpers.go index 1963951cd..e97fd2cb5 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/perconaxtradb_helpers.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/perconaxtradb_helpers.go @@ -117,6 +117,24 @@ func (p PerconaXtraDB) GetAuthSecretName() string { return meta_util.NameWithSuffix(p.OffshootName(), "auth") } +func (p PerconaXtraDB) GetReplicationSecretName() string { + if p.Spec.SystemUserSecrets != nil && + p.Spec.SystemUserSecrets.ReplicationUserSecret != nil && + p.Spec.SystemUserSecrets.ReplicationUserSecret.Name != "" { + return p.Spec.SystemUserSecrets.ReplicationUserSecret.Name + } + return meta_util.NameWithSuffix(p.OffshootName(), "replication") +} + +func (p PerconaXtraDB) GetMonitorSecretName() string { + if p.Spec.SystemUserSecrets != nil && + p.Spec.SystemUserSecrets.MonitorUserSecret != nil && + p.Spec.SystemUserSecrets.MonitorUserSecret.Name != "" { + return p.Spec.SystemUserSecrets.MonitorUserSecret.Name + } + return meta_util.NameWithSuffix(p.OffshootName(), "monitor") +} + func (p PerconaXtraDB) ClusterName() string { return p.OffshootName() } @@ -292,6 +310,12 @@ func (p *PerconaXtraDBSpec) GetPersistentSecrets() []string { if p.AuthSecret != nil { secrets = append(secrets, p.AuthSecret.Name) } + if p.SystemUserSecrets != nil && p.SystemUserSecrets.ReplicationUserSecret != nil { + secrets = append(secrets, p.SystemUserSecrets.ReplicationUserSecret.Name) + } + if p.SystemUserSecrets != nil && p.SystemUserSecrets.MonitorUserSecret != nil { + secrets = append(secrets, p.SystemUserSecrets.MonitorUserSecret.Name) + } return secrets } @@ -312,14 +336,6 @@ func (p *PerconaXtraDB) GetCertSecretName(alias PerconaXtraDBCertificateAlias) s return p.CertificateName(alias) } -func (p *PerconaXtraDB) ReplicationSecretName() string { - return meta_util.NameWithSuffix(p.Name, "replication") -} - -func (p *PerconaXtraDB) MonitorSecretName() string { - return meta_util.NameWithSuffix(p.Name, "monitor") -} - func (p *PerconaXtraDB) ReplicasAreReady(lister appslister.StatefulSetLister) (bool, string, error) { // Desire number of statefulSets expectedItems := 1 diff --git a/vendor/kubedb.dev/apimachinery/apis/postgres/v1alpha1/publisher_types.go b/vendor/kubedb.dev/apimachinery/apis/postgres/v1alpha1/publisher_types.go index 8377253f9..7f493d240 100644 --- a/vendor/kubedb.dev/apimachinery/apis/postgres/v1alpha1/publisher_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/postgres/v1alpha1/publisher_types.go @@ -118,6 +118,10 @@ const ( PublisherMessageDBServerCritical PublisherMessage = "Database Server is critical" PublisherMessageDBServerReady PublisherMessage = "Database Server is Ready" + PublisherConditionTypeDatabaseIsFound PublisherConditionType = "DatabaseIsFound" + PublisherMessageDatabaseIsFound PublisherMessage = "Database is found" + PublisherMessageDatabaseIsNotFound PublisherMessage = "Database is not found" + PublisherConditionTypeAllTablesFound PublisherConditionType = "AllTablesFound" PublisherMessageAllTablesNotFound PublisherMessage = "All tables are not found" PublisherMessageAllTablesFound PublisherMessage = "All tables are found" diff --git a/vendor/kubedb.dev/apimachinery/apis/postgres/v1alpha1/subscriber_types.go b/vendor/kubedb.dev/apimachinery/apis/postgres/v1alpha1/subscriber_types.go index 82a8f56ae..7bce32172 100644 --- a/vendor/kubedb.dev/apimachinery/apis/postgres/v1alpha1/subscriber_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/postgres/v1alpha1/subscriber_types.go @@ -129,6 +129,10 @@ const ( SubscriberMessageDBServerCritical SubscriberMessage = "Database Server is critical" SubscriberMessageDBServerReady SubscriberMessage = "Database Server is Ready" + SubscriberConditionTypeDatabaseIsFound SubscriberConditionType = "DatabaseIsFound" + SubscriberMessageDatabaseIsFound SubscriberMessage = "Database is found" + SubscriberMessageDatabaseIsNotFound SubscriberMessage = "Database is not found" + SubscriberConditionTypeAllPublisherReady SubscriberConditionType = "AllPublisherReady" SubscriberMessageAllPublisherAreReady SubscriberMessage = "All Publisher are ready" SubscriberMessageAllPublisherAreNotReady SubscriberMessage = "All Publisher are not ready" diff --git a/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_redissentinelautoscalers.yaml b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_redissentinelautoscalers.yaml index 768bc5757..6646bb8cf 100644 --- a/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_redissentinelautoscalers.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_redissentinelautoscalers.yaml @@ -96,25 +96,6 @@ spec: timeout: type: string type: object - storage: - properties: - sentinel: - properties: - expansionMode: - enum: - - Offline - - Online - type: string - scalingThreshold: - format: int32 - type: integer - trigger: - type: string - usageThreshold: - format: int32 - type: integer - type: object - type: object required: - databaseRef type: object diff --git a/vendor/modules.txt b/vendor/modules.txt index f7a32c39d..67df35f86 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -765,7 +765,7 @@ kmodules.xyz/offshoot-api/api/v1 # kmodules.xyz/prober v0.25.0 ## explicit; go 1.18 kmodules.xyz/prober/api/v1 -# kubedb.dev/apimachinery v0.28.4-0.20221007091615-35e1d5e5bcb6 +# kubedb.dev/apimachinery v0.29.0-rc.0 ## explicit; go 1.18 kubedb.dev/apimachinery/apis kubedb.dev/apimachinery/apis/autoscaling