Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bring back GetRequestType() #1064

Merged
merged 1 commit into from
Nov 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/elasticsearch_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ func (e *ElasticsearchOpsRequest) GetDBRefName() string {
return e.Spec.DatabaseRef.Name
}

func (e *ElasticsearchOpsRequest) GetRequestType() any {
return e.Spec.Type
}

func (e *ElasticsearchOpsRequest) GetStatus() OpsRequestStatus {
return e.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/etcd_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ func (e *EtcdOpsRequest) GetDBRefName() string {
return e.Spec.DatabaseRef.Name
}

func (e *EtcdOpsRequest) GetRequestType() any {
return e.Spec.Type
}

func (e *EtcdOpsRequest) GetStatus() OpsRequestStatus {
return e.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/kafka_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,10 @@ func (k *KafkaOpsRequest) GetDBRefName() string {
return k.Spec.DatabaseRef.Name
}

func (k *KafkaOpsRequest) GetRequestType() any {
return k.Spec.Type
}

func (k *KafkaOpsRequest) GetStatus() OpsRequestStatus {
return k.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/mariadb_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,10 @@ func (m *MariaDBOpsRequest) GetDBRefName() string {
return m.Spec.DatabaseRef.Name
}

func (m *MariaDBOpsRequest) GetRequestType() any {
return m.Spec.Type
}

func (m *MariaDBOpsRequest) GetStatus() OpsRequestStatus {
return m.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/memcached_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ func (m *MemcachedOpsRequest) GetDBRefName() string {
return m.Spec.DatabaseRef.Name
}

func (m *MemcachedOpsRequest) GetRequestType() any {
return m.Spec.Type
}

func (m *MemcachedOpsRequest) GetStatus() OpsRequestStatus {
return m.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/mongodb_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ func (m *MongoDBOpsRequest) GetDBRefName() string {
return m.Spec.DatabaseRef.Name
}

func (m *MongoDBOpsRequest) GetRequestType() any {
return m.Spec.Type
}

func (m *MongoDBOpsRequest) GetStatus() OpsRequestStatus {
return m.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/mysql_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ func (m *MySQLOpsRequest) GetDBRefName() string {
return m.Spec.DatabaseRef.Name
}

func (m *MySQLOpsRequest) GetRequestType() any {
return m.Spec.Type
}

func (m *MySQLOpsRequest) GetStatus() OpsRequestStatus {
return m.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/perconaxtradb_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ func (p *PerconaXtraDBOpsRequest) GetDBRefName() string {
return p.Spec.DatabaseRef.Name
}

func (p *PerconaXtraDBOpsRequest) GetRequestType() any {
return p.Spec.Type
}

func (p *PerconaXtraDBOpsRequest) GetStatus() OpsRequestStatus {
return p.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/pgbouncer_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ func (p *PgBouncerOpsRequest) GetDBRefName() string {
return p.Spec.ServerRef.Name
}

func (p *PgBouncerOpsRequest) GetRequestType() any {
return p.Spec.Type
}

func (p *PgBouncerOpsRequest) GetStatus() OpsRequestStatus {
return p.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/postgres_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ func (p *PostgresOpsRequest) GetDBRefName() string {
return p.Spec.DatabaseRef.Name
}

func (p *PostgresOpsRequest) GetRequestType() any {
return p.Spec.Type
}

func (p *PostgresOpsRequest) GetStatus() OpsRequestStatus {
return p.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/proxysql_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,10 @@ func (p *ProxySQLOpsRequest) GetDBRefName() string {
return p.Spec.ProxyRef.Name
}

func (p *ProxySQLOpsRequest) GetRequestType() any {
return p.Spec.Type
}

func (p *ProxySQLOpsRequest) GetStatus() OpsRequestStatus {
return p.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/redis_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ func (r *RedisOpsRequest) GetDBRefName() string {
return r.Spec.DatabaseRef.Name
}

func (r *RedisOpsRequest) GetRequestType() any {
return r.Spec.Type
}

func (r *RedisOpsRequest) GetStatus() OpsRequestStatus {
return r.Status
}
Expand Down
4 changes: 4 additions & 0 deletions apis/ops/v1alpha1/redis_sentinel_ops_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ func (r *RedisSentinelOpsRequest) GetDBRefName() string {
return r.Spec.DatabaseRef.Name
}

func (r *RedisSentinelOpsRequest) GetRequestType() any {
return r.Spec.Type
}

func (r *RedisSentinelOpsRequest) GetStatus() OpsRequestStatus {
return r.Status
}
Expand Down
1 change: 1 addition & 0 deletions apis/ops/v1alpha1/type.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ const (
type Accessor interface {
GetObjectMeta() metav1.ObjectMeta
GetDBRefName() string
GetRequestType() any
GetStatus() OpsRequestStatus
SetStatus(_ OpsRequestStatus)
}
24 changes: 0 additions & 24 deletions openapi/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -33403,10 +33403,6 @@
"description": "Specifies information necessary for upgrading Elasticsearch",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.ElasticsearchUpdateVersionSpec"
},
"upgrade": {
"description": "Specifies information necessary for upgrading Elasticsearch Deprecated: use UpdateVersion",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.ElasticsearchUpdateVersionSpec"
},
"verticalScaling": {
"description": "Specifies information necessary for vertical scaling",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.ElasticsearchVerticalScalingSpec"
Expand Down Expand Up @@ -33818,10 +33814,6 @@
"description": "Specifies information necessary for upgrading Memcached",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.MemcachedUpdateVersionSpec"
},
"upgrade": {
"description": "Specifies information necessary for upgrading Memcached Deprecated: use UpdateVersion",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.MemcachedUpdateVersionSpec"
},
"verticalScaling": {
"description": "Specifies information necessary for vertical scaling",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.MemcachedVerticalScalingSpec"
Expand Down Expand Up @@ -34050,10 +34042,6 @@
"description": "Specifies information necessary for upgrading MongoDB",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.MongoDBUpdateVersionSpec"
},
"upgrade": {
"description": "Specifies information necessary for upgrading MongoDB Deprecated: use UpdateVersion",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.MongoDBUpdateVersionSpec"
},
"verticalScaling": {
"description": "Specifies information necessary for vertical scaling",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.MongoDBVerticalScalingSpec"
Expand Down Expand Up @@ -34303,10 +34291,6 @@
"description": "Specifies information necessary for upgrading MySQL",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.MySQLUpdateVersionSpec"
},
"upgrade": {
"description": "Specifies information necessary for upgrading MySQL Deprecated: use UpdateVersion",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.MySQLUpdateVersionSpec"
},
"verticalScaling": {
"description": "Specifies information necessary for vertical scaling",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.MySQLVerticalScalingSpec"
Expand Down Expand Up @@ -34600,10 +34584,6 @@
"description": "Specifies information necessary for upgrading PerconaXtraDB",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.PerconaXtraDBUpdateVersionSpec"
},
"upgrade": {
"description": "Specifies information necessary for upgrading PerconaXtraDB Deprecated: use UpdateVersion",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.PerconaXtraDBUpdateVersionSpec"
},
"verticalScaling": {
"description": "Specifies information necessary for vertical scaling",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.PerconaXtraDBVerticalScalingSpec"
Expand Down Expand Up @@ -34822,10 +34802,6 @@
"description": "Specifies information necessary for upgrading Postgres",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.PostgresUpdateVersionSpec"
},
"upgrade": {
"description": "Specifies information necessary for upgrading Postgres Deprecated: use UpdateVersion",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.PostgresUpdateVersionSpec"
},
"verticalScaling": {
"description": "Specifies information necessary for vertical scaling",
"$ref": "#/definitions/dev.kubedb.apimachinery.apis.ops.v1alpha1.PostgresVerticalScalingSpec"
Expand Down
Loading