From 76d9e55cc83cb4f11c372f4b6b4b6247378efbbc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 29 Jan 2024 08:16:09 +0000 Subject: [PATCH] build(deps): bump github.com/aiven/go-api-schemas from 1.56.0 to 1.57.0 (#611) --- CHANGELOG.md | 3 +++ api/v1alpha1/userconfig/service/cassandra/cassandra.go | 2 +- api/v1alpha1/userconfig/service/kafka/kafka.go | 4 ++++ .../userconfig/service/kafka/zz_generated.deepcopy.go | 5 +++++ api/v1alpha1/userconfig/service/redis/redis.go | 4 ++++ .../userconfig/service/redis/zz_generated.deepcopy.go | 5 +++++ .../templates/aiven.io_cassandras.yaml | 2 +- .../aiven-operator-crds/templates/aiven.io_kafkas.yaml | 9 +++++++++ charts/aiven-operator-crds/templates/aiven.io_redis.yaml | 5 +++++ config/crd/bases/aiven.io_cassandras.yaml | 2 +- config/crd/bases/aiven.io_kafkas.yaml | 9 +++++++++ config/crd/bases/aiven.io_redis.yaml | 5 +++++ docs/docs/api-reference/cassandra.md | 2 +- docs/docs/api-reference/kafka.md | 1 + docs/docs/api-reference/redis.md | 1 + go.mod | 4 ++-- go.sum | 4 ++-- 17 files changed, 59 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index adb81e5a..f2a134d1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -61,6 +61,9 @@ connection information will not be created, defaults to false - Add `ServiceUser` field `connInfoSecretTargetDisabled`, type `boolean`: When true, the secret containing connection information will not be created, defaults to false +- Add `Kafka` field `userConfig.kafka_rest_config.name_strategy`, type `string`: Name strategy to use + when selecting subject for storing schemas +- Add `Redis` field `userConfig.redis_version`, type `string`: Redis major version ## v0.16.1 - 2023-12-15 diff --git a/api/v1alpha1/userconfig/service/cassandra/cassandra.go b/api/v1alpha1/userconfig/service/cassandra/cassandra.go index 736fe4de..e9d85136 100644 --- a/api/v1alpha1/userconfig/service/cassandra/cassandra.go +++ b/api/v1alpha1/userconfig/service/cassandra/cassandra.go @@ -62,7 +62,7 @@ type CassandraUserConfig struct { Cassandra *Cassandra `groups:"create,update" json:"cassandra,omitempty"` // +kubebuilder:validation:Enum="4";"4.1" - // Cassandra major version + // Cassandra version CassandraVersion *string `groups:"create,update" json:"cassandra_version,omitempty"` // +kubebuilder:validation:MaxItems=1024 diff --git a/api/v1alpha1/userconfig/service/kafka/kafka.go b/api/v1alpha1/userconfig/service/kafka/kafka.go index 855a4753..6fec11fc 100644 --- a/api/v1alpha1/userconfig/service/kafka/kafka.go +++ b/api/v1alpha1/userconfig/service/kafka/kafka.go @@ -325,6 +325,10 @@ type KafkaRestConfig struct { // The maximum total time to wait for messages for a request if the maximum number of messages has not yet been reached ConsumerRequestTimeoutMs *int `groups:"create,update" json:"consumer_request_timeout_ms,omitempty"` + // +kubebuilder:validation:Enum="topic_name";"record_name";"topic_record_name" + // Name strategy to use when selecting subject for storing schemas + NameStrategy *string `groups:"create,update" json:"name_strategy,omitempty"` + // If true, validate that given schema is registered under expected subject name by the used name strategy when producing messages. NameStrategyValidation *bool `groups:"create,update" json:"name_strategy_validation,omitempty"` diff --git a/api/v1alpha1/userconfig/service/kafka/zz_generated.deepcopy.go b/api/v1alpha1/userconfig/service/kafka/zz_generated.deepcopy.go index cabbdfe5..9dacbdca 100644 --- a/api/v1alpha1/userconfig/service/kafka/zz_generated.deepcopy.go +++ b/api/v1alpha1/userconfig/service/kafka/zz_generated.deepcopy.go @@ -410,6 +410,11 @@ func (in *KafkaRestConfig) DeepCopyInto(out *KafkaRestConfig) { *out = new(int) **out = **in } + if in.NameStrategy != nil { + in, out := &in.NameStrategy, &out.NameStrategy + *out = new(string) + **out = **in + } if in.NameStrategyValidation != nil { in, out := &in.NameStrategyValidation, &out.NameStrategyValidation *out = new(bool) diff --git a/api/v1alpha1/userconfig/service/redis/redis.go b/api/v1alpha1/userconfig/service/redis/redis.go index 2ee14a52..f9e2a989 100644 --- a/api/v1alpha1/userconfig/service/redis/redis.go +++ b/api/v1alpha1/userconfig/service/redis/redis.go @@ -157,6 +157,10 @@ type RedisUserConfig struct { // Redis idle connection timeout in seconds RedisTimeout *int `groups:"create,update" json:"redis_timeout,omitempty"` + // +kubebuilder:validation:Enum="7.0" + // Redis major version + RedisVersion *string `groups:"create,update" json:"redis_version,omitempty"` + // Store logs for the service so that they are available in the HTTP API and console. ServiceLog *bool `groups:"create,update" json:"service_log,omitempty"` diff --git a/api/v1alpha1/userconfig/service/redis/zz_generated.deepcopy.go b/api/v1alpha1/userconfig/service/redis/zz_generated.deepcopy.go index 65148de8..c9f1373f 100644 --- a/api/v1alpha1/userconfig/service/redis/zz_generated.deepcopy.go +++ b/api/v1alpha1/userconfig/service/redis/zz_generated.deepcopy.go @@ -251,6 +251,11 @@ func (in *RedisUserConfig) DeepCopyInto(out *RedisUserConfig) { *out = new(int) **out = **in } + if in.RedisVersion != nil { + in, out := &in.RedisVersion, &out.RedisVersion + *out = new(string) + **out = **in + } if in.ServiceLog != nil { in, out := &in.ServiceLog, &out.ServiceLog *out = new(bool) diff --git a/charts/aiven-operator-crds/templates/aiven.io_cassandras.yaml b/charts/aiven-operator-crds/templates/aiven.io_cassandras.yaml index 9b527ae2..b2ccc320 100644 --- a/charts/aiven-operator-crds/templates/aiven.io_cassandras.yaml +++ b/charts/aiven-operator-crds/templates/aiven.io_cassandras.yaml @@ -269,7 +269,7 @@ spec: type: string type: object cassandra_version: - description: Cassandra major version + description: Cassandra version enum: - "4" - "4.1" diff --git a/charts/aiven-operator-crds/templates/aiven.io_kafkas.yaml b/charts/aiven-operator-crds/templates/aiven.io_kafkas.yaml index 774886c4..589d8930 100644 --- a/charts/aiven-operator-crds/templates/aiven.io_kafkas.yaml +++ b/charts/aiven-operator-crds/templates/aiven.io_kafkas.yaml @@ -799,6 +799,15 @@ spec: maximum: 30000 minimum: 1000 type: integer + name_strategy: + description: + Name strategy to use when selecting subject for + storing schemas + enum: + - topic_name + - record_name + - topic_record_name + type: string name_strategy_validation: description: If true, validate that given schema is registered diff --git a/charts/aiven-operator-crds/templates/aiven.io_redis.yaml b/charts/aiven-operator-crds/templates/aiven.io_redis.yaml index b2607740..fe95067b 100644 --- a/charts/aiven-operator-crds/templates/aiven.io_redis.yaml +++ b/charts/aiven-operator-crds/templates/aiven.io_redis.yaml @@ -434,6 +434,11 @@ spec: maximum: 31536000 minimum: 0 type: integer + redis_version: + description: Redis major version + enum: + - "7.0" + type: string service_log: description: Store logs for the service so that they are available diff --git a/config/crd/bases/aiven.io_cassandras.yaml b/config/crd/bases/aiven.io_cassandras.yaml index 9b527ae2..b2ccc320 100644 --- a/config/crd/bases/aiven.io_cassandras.yaml +++ b/config/crd/bases/aiven.io_cassandras.yaml @@ -269,7 +269,7 @@ spec: type: string type: object cassandra_version: - description: Cassandra major version + description: Cassandra version enum: - "4" - "4.1" diff --git a/config/crd/bases/aiven.io_kafkas.yaml b/config/crd/bases/aiven.io_kafkas.yaml index 774886c4..589d8930 100644 --- a/config/crd/bases/aiven.io_kafkas.yaml +++ b/config/crd/bases/aiven.io_kafkas.yaml @@ -799,6 +799,15 @@ spec: maximum: 30000 minimum: 1000 type: integer + name_strategy: + description: + Name strategy to use when selecting subject for + storing schemas + enum: + - topic_name + - record_name + - topic_record_name + type: string name_strategy_validation: description: If true, validate that given schema is registered diff --git a/config/crd/bases/aiven.io_redis.yaml b/config/crd/bases/aiven.io_redis.yaml index b2607740..fe95067b 100644 --- a/config/crd/bases/aiven.io_redis.yaml +++ b/config/crd/bases/aiven.io_redis.yaml @@ -434,6 +434,11 @@ spec: maximum: 31536000 minimum: 0 type: integer + redis_version: + description: Redis major version + enum: + - "7.0" + type: string service_log: description: Store logs for the service so that they are available diff --git a/docs/docs/api-reference/cassandra.md b/docs/docs/api-reference/cassandra.md index c4290aa0..1fe72888 100644 --- a/docs/docs/api-reference/cassandra.md +++ b/docs/docs/api-reference/cassandra.md @@ -152,7 +152,7 @@ Cassandra specific user configuration options. - [`backup_hour`](#spec.userConfig.backup_hour-property){: name='spec.userConfig.backup_hour-property'} (integer, Minimum: 0, Maximum: 23). The hour of day (in UTC) when backup for the service is started. New backup is only started if previous backup has already completed. - [`backup_minute`](#spec.userConfig.backup_minute-property){: name='spec.userConfig.backup_minute-property'} (integer, Minimum: 0, Maximum: 59). The minute of an hour when backup for the service is started. New backup is only started if previous backup has already completed. - [`cassandra`](#spec.userConfig.cassandra-property){: name='spec.userConfig.cassandra-property'} (object). cassandra configuration values. See below for [nested schema](#spec.userConfig.cassandra). -- [`cassandra_version`](#spec.userConfig.cassandra_version-property){: name='spec.userConfig.cassandra_version-property'} (string, Enum: `4`, `4.1`). Cassandra major version. +- [`cassandra_version`](#spec.userConfig.cassandra_version-property){: name='spec.userConfig.cassandra_version-property'} (string, Enum: `4`, `4.1`). Cassandra version. - [`ip_filter`](#spec.userConfig.ip_filter-property){: name='spec.userConfig.ip_filter-property'} (array of objects, MaxItems: 1024). Allow incoming connections from CIDR address block, e.g. `10.20.0.0/16`. See below for [nested schema](#spec.userConfig.ip_filter). - [`migrate_sstableloader`](#spec.userConfig.migrate_sstableloader-property){: name='spec.userConfig.migrate_sstableloader-property'} (boolean). Sets the service into migration mode enabling the sstableloader utility to be used to upload Cassandra data files. Available only on service create. - [`private_access`](#spec.userConfig.private_access-property){: name='spec.userConfig.private_access-property'} (object). Allow access to selected service ports from private networks. See below for [nested schema](#spec.userConfig.private_access). diff --git a/docs/docs/api-reference/kafka.md b/docs/docs/api-reference/kafka.md index 1e8b5766..abad7aa9 100644 --- a/docs/docs/api-reference/kafka.md +++ b/docs/docs/api-reference/kafka.md @@ -277,6 +277,7 @@ Kafka REST configuration. - [`consumer_enable_auto_commit`](#spec.userConfig.kafka_rest_config.consumer_enable_auto_commit-property){: name='spec.userConfig.kafka_rest_config.consumer_enable_auto_commit-property'} (boolean). If true the consumer's offset will be periodically committed to Kafka in the background. - [`consumer_request_max_bytes`](#spec.userConfig.kafka_rest_config.consumer_request_max_bytes-property){: name='spec.userConfig.kafka_rest_config.consumer_request_max_bytes-property'} (integer, Minimum: 0, Maximum: 671088640). Maximum number of bytes in unencoded message keys and values by a single request. - [`consumer_request_timeout_ms`](#spec.userConfig.kafka_rest_config.consumer_request_timeout_ms-property){: name='spec.userConfig.kafka_rest_config.consumer_request_timeout_ms-property'} (integer, Enum: `1000`, `15000`, `30000`, Minimum: 1000, Maximum: 30000). The maximum total time to wait for messages for a request if the maximum number of messages has not yet been reached. +- [`name_strategy`](#spec.userConfig.kafka_rest_config.name_strategy-property){: name='spec.userConfig.kafka_rest_config.name_strategy-property'} (string, Enum: `topic_name`, `record_name`, `topic_record_name`). Name strategy to use when selecting subject for storing schemas. - [`name_strategy_validation`](#spec.userConfig.kafka_rest_config.name_strategy_validation-property){: name='spec.userConfig.kafka_rest_config.name_strategy_validation-property'} (boolean). If true, validate that given schema is registered under expected subject name by the used name strategy when producing messages. - [`producer_acks`](#spec.userConfig.kafka_rest_config.producer_acks-property){: name='spec.userConfig.kafka_rest_config.producer_acks-property'} (string, Enum: `all`, `-1`, `0`, `1`). The number of acknowledgments the producer requires the leader to have received before considering a request complete. If set to `all` or `-1`, the leader will wait for the full set of in-sync replicas to acknowledge the record. - [`producer_compression_type`](#spec.userConfig.kafka_rest_config.producer_compression_type-property){: name='spec.userConfig.kafka_rest_config.producer_compression_type-property'} (string, Enum: `gzip`, `snappy`, `lz4`, `zstd`, `none`). Specify the default compression type for producers. This configuration accepts the standard compression codecs (`gzip`, `snappy`, `lz4`, `zstd`). It additionally accepts `none` which is the default and equivalent to no compression. diff --git a/docs/docs/api-reference/redis.md b/docs/docs/api-reference/redis.md index 6de1298a..ed5c4a36 100644 --- a/docs/docs/api-reference/redis.md +++ b/docs/docs/api-reference/redis.md @@ -161,6 +161,7 @@ Redis specific user configuration options. - [`redis_pubsub_client_output_buffer_limit`](#spec.userConfig.redis_pubsub_client_output_buffer_limit-property){: name='spec.userConfig.redis_pubsub_client_output_buffer_limit-property'} (integer, Minimum: 32, Maximum: 512). Set output buffer limit for pub / sub clients in MB. The value is the hard limit, the soft limit is 1/4 of the hard limit. When setting the limit, be mindful of the available memory in the selected service plan. - [`redis_ssl`](#spec.userConfig.redis_ssl-property){: name='spec.userConfig.redis_ssl-property'} (boolean). Require SSL to access Redis. - [`redis_timeout`](#spec.userConfig.redis_timeout-property){: name='spec.userConfig.redis_timeout-property'} (integer, Minimum: 0, Maximum: 31536000). Redis idle connection timeout in seconds. +- [`redis_version`](#spec.userConfig.redis_version-property){: name='spec.userConfig.redis_version-property'} (string, Enum: `7.0`). Redis major version. - [`service_log`](#spec.userConfig.service_log-property){: name='spec.userConfig.service_log-property'} (boolean). Store logs for the service so that they are available in the HTTP API and console. - [`service_to_fork_from`](#spec.userConfig.service_to_fork_from-property){: name='spec.userConfig.service_to_fork_from-property'} (string, Immutable, MaxLength: 64). Name of another service to fork from. This has effect only when a new service is being created. - [`static_ips`](#spec.userConfig.static_ips-property){: name='spec.userConfig.static_ips-property'} (boolean). Use static public IP addresses. diff --git a/go.mod b/go.mod index 59e3d9dc..62d2ca63 100644 --- a/go.mod +++ b/go.mod @@ -4,7 +4,7 @@ go 1.21 require ( github.com/aiven/aiven-go-client/v2 v2.12.0 - github.com/aiven/go-api-schemas v1.56.0 + github.com/aiven/go-api-schemas v1.57.0 github.com/dave/jennifer v1.7.0 github.com/docker/go-units v0.5.0 github.com/ghodss/yaml v1.0.0 @@ -22,6 +22,7 @@ require ( k8s.io/api v0.26.13 k8s.io/apimachinery v0.26.13 k8s.io/client-go v0.26.13 + k8s.io/utils v0.0.0-20221128185143-99ec85e7a448 sigs.k8s.io/controller-runtime v0.14.7 ) @@ -81,7 +82,6 @@ require ( k8s.io/component-base v0.26.10 // indirect k8s.io/klog/v2 v2.80.1 // indirect k8s.io/kube-openapi v0.0.0-20221012153701-172d655c2280 // indirect - k8s.io/utils v0.0.0-20221128185143-99ec85e7a448 // indirect sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2 // indirect sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect sigs.k8s.io/yaml v1.3.0 // indirect diff --git a/go.sum b/go.sum index c432af5b..52740b7f 100644 --- a/go.sum +++ b/go.sum @@ -35,8 +35,8 @@ github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03 github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/aiven/aiven-go-client/v2 v2.12.0 h1:VxOfn61AtfLjy2B+DdXF2/7OHyyFZ1aQaIlE3TOyIsE= github.com/aiven/aiven-go-client/v2 v2.12.0/go.mod h1:x0xhzxWEKAwKv0xY5FvECiI6tesWshcPHvjwl0B/1SU= -github.com/aiven/go-api-schemas v1.56.0 h1:sUYu6WeHnfgUfG+puON42C5j45di8zXy8L0KhI1YBSE= -github.com/aiven/go-api-schemas v1.56.0/go.mod h1:/bPxBUHza/2Aeer6hIIdB++GxKiw9K1KCBtRa2rtZ5I= +github.com/aiven/go-api-schemas v1.57.0 h1:ZUQOdtmOgDw64Rvb+WBHDcgvbFUtxMILCxmbb50tsvw= +github.com/aiven/go-api-schemas v1.57.0/go.mod h1:/bPxBUHza/2Aeer6hIIdB++GxKiw9K1KCBtRa2rtZ5I= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0=