canonical/kafka-operator

Feature request: allow for ignoring specific topics with ReplicationFactor: 1

Closed this issue · 2 comments

Hi,

On a customer's Charmed Kafka environment, we are getting alerts for their environment regarding 5 topics for which the ReplicationFactor is set to 1. Specifically, the alert we receive look like this:

Labels:
 - alertname = Not Replicated Topic
 - juju_application = kafka
 - juju_charm = kafka
 - juju_model = preprod-kafka
 - juju_model_uuid = <REDACTED>
 - partition = 0
 - severity = warning
 - topic = quickstart-config
Annotations:
 - description = The topic is subject to data loss if the partition goes down and data cannot be recovered.
 - summary = Topic quickstart-config - Partition 0 :: Replicas and Partitions :: The IRS for the topic is lower or equal than 1.
Source: http://<REDACTED>:80/cos-prometheus-0/graph?g0.expr=count+by+%28topic%2C+partition%29+%28kafka_cluster_partition_insyncreplicascount%7Bjuju_application%3D%22kafka%22%2Cjuju_charm%21%3D%22.%2A%22%2Cjuju_model%3D%22preprod-kafka%22%2Cjuju_model_uuid%3D%<REDACTED>%22%7D%29+%3C%3D+1&g0.tab=1

I don't know if this is specifically a bug in Charmed Kafka, or something related to the COS - but in the case of topics intentionally set to ReplicationFactor of 1, is there some way we could ignore those events while still allowing the other events to come through?

If not, we're going to get alerts anytime someone decides to go through e.g. the Confluent quickstart without adjusting the replication threshold appropriately, and if we can't somehow ignore such topics, it will make it more difficult to rely on this type of alert.

Best Regards,
Paul Goins

Sorry - I am not yet used to AlertManager. It allows us to do exactly what I asked for without any special logic here; I just need to create the appropriate silence.

I think no action is required here; sorry for the interruption.