Alert Rules

Lenses provides a set with pre-configured Alert Rules and the ability to create Consumer Alert rules. When rules are enabled, Lenses monitors the relevant resources and triggers an Alert Event any time the condition is met. Events can be integrated with any third party system via the Alert Integration plugins.

  1. From the Header Bar Menu, go to Admin panel.
  2. On the side navigation, select Rules under the Alerts section.

Alert Rule types

Two types of Alert Rules are supported in Lenses:

Infrastructure are built-in rules. They can be enabled or disabled but also can be routed into any channel you configured.

AlertDescription
Kafka Broker is downRaised when the Kafka broker is not part of the cluster for at least 1 minute. i.e:host-1,host-2
Zookeeper Node is downRaised when the Zookeeper node is not reachable. This information is based on the Zookeeper JMX. If it responds to JMX queries it is considered to be running.
Schema Registry is downRaised when the Schema Registry node is not responding to the root API call for more than 1 minute.
Alert Manager is downRaised when the AlertManager has not been seen online for more than 1 minute.
Connect worker is downRaised when the Kafka Connect worker is not responding to the API call for /connectors for more than 1 minute.
Under replicated partitionsRaised when there are (topic, partitions) not meeting the replication factor set.
Partitions offlineRaised when there are partitions which do not have an active leader. These partitions are not writable or readable.
Active controllersRaised when the number of active controllers is not 1. Each cluster should have exactly one controller.
Multiple Broker VersionsRaised when there are brokers in the cluster running on different Kafka version.
File-open descriptors high capacity on BrokersRaised when a Kafka Broker OS file descriptors count exceeds 90% of the available operating system file descriptors.
Average % the request handler is idleRaised when the average fraction of time the request handler threads are idle. When the value is smaller than 0.02 the alert level is CRITICAL. When the value is smaller than 0.1 the alert level is HIGH.
Fetch requests failureRaised when the Fetch request rate (the value is per second) for requests that failed is greater than a threshold. If the value is greater than 0.1 the alert level is set to CRITICAL otherwise is set to HIGH.
Produce requests failureRaised when the Producer request rate (the value is per second) for requests that failed is greater than a threshold. If the value is greater than 0.1 the alert level is set to CRITICAL otherwise is set to HIGH.
Broker disk usage is greater than the cluster averageRaised when the Kafka Broker disk usage is greater than the cluster average. We provide by default a threshold of 1GB disk usage.
Leader imbalanceRaised when the Kafka Broker has more leader replicas than the cluster average.

Consumer rules refer to the Kafka Consumers, and are based on threshold added by the user. Similarly to Infrastructure rules, you can also specify which channel they will be routed to.

From this screen, you can also edit their destination by clicking on the edit icon next to each rule.

Alert Rules Infrastructure

Creating consumer rule

To create a new rule, click on the New Rule button from the listing page.

Alert Rules Consumer Rules Create

Editing a consumer Rule

To edit Consumer rule, click on the edit icon next to the desired rule from the listing page.

Alert Rules Consumer Rules Edit

Deleting a consumer rule

To delete Consumer rule, click on the trash icon next to the desired rule from the listing page.

Alert Rules Consumer Rules Delete

Data Produced Rules refer to the Kafka topics and are based on the threshold added by the user. Similarly to Infrastructure rules, you can also specify which channel they will be routed to.

From this screen, you can also edit their destination by clicking on the edit icon next to each rule. Data Produced rules cannot be disabled, but they can be deleted.

Creating a data produced rule

To create a new rule, click on the New Rule button from the listing page.

Alert Rules Data Produced Rules Create

Editing a data produced rule

To edit Data Produced rule, click on the edit icon next to the desired rule from the listing page.

Alert Rules Data Produced Rules Edit

Deleting data produced rule

To delete Data Produced rule, click on the trash icon next to the desired rule from the listing page.

Alert Rules Data Produced Rules Delete