From 0fdae21f36b8d0b71fe58e24ee4c9f1f5757cb2e Mon Sep 17 00:00:00 2001 From: Kirill Salnikov Date: Tue, 10 Dec 2024 17:16:52 +0300 Subject: [PATCH] fix groupId usage, upd docs --- charts/keys/README.md | 38 +++++++++++++++---------------- charts/keys/templates/helpers.tpl | 4 ++-- charts/keys/values.yaml | 4 ++-- 3 files changed, 23 insertions(+), 23 deletions(-) diff --git a/charts/keys/README.md b/charts/keys/README.md index ba9bd561..f93a626e 100644 --- a/charts/keys/README.md +++ b/charts/keys/README.md @@ -253,25 +253,25 @@ See the [documentation](https://docs.2gis.com/en/on-premise/keys) to learn about ### Kafka settings -| Name | Description | Value | -| --------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------ | -| `kafka.bootstrapServers` | Comma-separated list of host and port pairs that are the addresses of the Kafka brokers (e.g. 'localhost:9092,localhost:9093'). **Required** | `""` | -| `kafka.securityProtocol` | Protocol used to communicate with brokers. Valid values are: PLAINTEXT, SSL, SASL_PLAINTEXT, SASL_SSL. Default: PLAINTEXT. | `PLAINTEXT` | -| `kafka.saslMechanism` | Authentication mechanism when security_protocol is configured for SASL_PLAINTEXT or SASL_SSL. Valid values are: PLAIN, SCRAM-SHA-256, SCRAM-SHA-512. | `PLAIN` | -| `kafka.username` | Username for authorization (SASL). | `""` | -| `kafka.password` | Password for authorization (SASL). | `""` | -| `kafka.tls.skipServerCertificateVerify` | Controls whether a client verifies the server's certificate chain and host name. | `false` | -| `kafka.tls.rootCert` | Root certificate. | `""` | -| `kafka.tls.cert` | Client certificate. | `""` | -| `kafka.tls.key` | Client key. | `""` | -| `kafka.stats` | **Settings for consuming key's usage statistics messages.** | | -| `kafka.stats.topic` | Topic to consume stat messages from. **Required** | `""` | -| `kafka.stats.clientPrefix` | Prefix for client name. | `production` | -| `kafka.stats.clientId` | Client id. If empty hostname will be used. | `""` | -| `kafka.audit` | **Settings for sending audit messages.** | | -| `kafka.audit.topic` | Topic to produce audit messages. **Required** | `""` | -| `kafka.audit.produce.retryCount` | Number of retries to produce a message. | `5` | -| `kafka.audit.produce.idempotentWrite` | Flag to enable/disable [idempotent write](https://docs.confluent.io/platform/current/installation/configuration/producer-configs.html#enable-idempotence). | `true` | +| Name | Description | Value | +| --------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------- | +| `kafka.bootstrapServers` | Comma-separated list of host and port pairs that are the addresses of the Kafka brokers (e.g. 'localhost:9092,localhost:9093'). **Required** | `""` | +| `kafka.securityProtocol` | Protocol used to communicate with brokers. Valid values are: PLAINTEXT, SSL, SASL_PLAINTEXT, SASL_SSL. Default: PLAINTEXT. | `PLAINTEXT` | +| `kafka.saslMechanism` | Authentication mechanism when security_protocol is configured for SASL_PLAINTEXT or SASL_SSL. Valid values are: PLAIN, SCRAM-SHA-256, SCRAM-SHA-512. | `PLAIN` | +| `kafka.username` | Username for authorization (SASL). | `""` | +| `kafka.password` | Password for authorization (SASL). | `""` | +| `kafka.tls.skipServerCertificateVerify` | Controls whether a client verifies the server's certificate chain and host name. | `false` | +| `kafka.tls.rootCert` | Root certificate. | `""` | +| `kafka.tls.cert` | Client certificate. | `""` | +| `kafka.tls.key` | Client key. | `""` | +| `kafka.stats` | **Settings for consuming key's usage statistics messages.** | | +| `kafka.stats.topic` | Topic to consume stat messages from. **Required** | `""` | +| `kafka.stats.groupId` | Name of the consumer group to use. **Required** | `""` | +| `kafka.stats.clientId` | Client id. If empty hostname will be used. | `""` | +| `kafka.audit` | **Settings for sending audit messages.** | | +| `kafka.audit.topic` | Topic to produce audit messages. **Required** | `""` | +| `kafka.audit.produce.retryCount` | Number of retries to produce a message. | `5` | +| `kafka.audit.produce.idempotentWrite` | Flag to enable/disable [idempotent write](https://docs.confluent.io/platform/current/installation/configuration/producer-configs.html#enable-idempotence). | `true` | ### LDAP connection settings diff --git a/charts/keys/templates/helpers.tpl b/charts/keys/templates/helpers.tpl index 2ea804f7..fe5bcde6 100644 --- a/charts/keys/templates/helpers.tpl +++ b/charts/keys/templates/helpers.tpl @@ -351,8 +351,8 @@ app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} value: "{{ .Values.counter.updateStatusQueryTimeout }}" - name: KEYS_KAFKA_MAIN_BROKERS value: "{{ required "A valid .Values.kafka.bootstrapServers entry required" .Values.kafka.bootstrapServers }}" -- name: KEYS_KAFKA_MAIN_CLIENT_PREFIX - value: "{{ .Values.kafka.stats.clientPrefix }}" +- name: KEYS_KAFKA_MAIN_GROUP_ID + value: "{{ required "A valid .Values.kafka.stats.groupId entry required" .Values.kafka.stats.groupId }}" - name: KEYS_KAFKA_MAIN_CLIENT_ID value: "{{ .Values.kafka.stats.clientId }}" - name: KEYS_KAFKA_MAIN_STATS_TOPIC diff --git a/charts/keys/values.yaml b/charts/keys/values.yaml index 57eba30d..306a17ca 100644 --- a/charts/keys/values.yaml +++ b/charts/keys/values.yaml @@ -637,12 +637,12 @@ kafka: # @extra kafka.stats **Settings for consuming key's usage statistics messages.** # @param kafka.stats.topic Topic to consume stat messages from. **Required** - # @param kafka.stats.clientPrefix Prefix for client name. + # @param kafka.stats.groupId Name of the consumer group to use. **Required** # @param kafka.stats.clientId Client id. If empty hostname will be used. stats: topic: '' - groupId: production-keys-counter + groupId: '' clientId: '' # @extra kafka.audit **Settings for sending audit messages.**