question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Disabling Kafka health check is not working.

See original GitHub issue

Describe the bug Disabling Kafka health check by configuring quarkus.kafka.health.enabled=false is not working as expected. Expected behavior On configuring quarkus.kafka.health.enabled=false Kafka health must not run

Actual behavior It runs the health even after setting quarkus.kafka.health.enabled=false. It returns below response

HTTP/1.1 503 Service Unavailable
content-length: 245
content-type: application/json; charset=UTF-8

{
    "checks": [
        {
            "data": {
                "kafka-connector": "[KO]"
            },
            "name": "SmallRye Reactive Messaging - readiness check",
            "status": "DOWN"
        }
    ],
    "status": "DOWN"
}

To Reproduce

Link to a small reproducer (preferably a Maven project if the issue is not Gradle-specific).

Or attach an archive containing the reproducer to the issue.

Steps to reproduce the behavior:

  1. Create Quarkus application
  2. Add quarkus-smallrye-reactive-messaging-kafka , quarkus-smallrye-health dependencies
  3. Add quarkus.kafka.health.enabled=false
  4. Call health REST endpoint for example http localhost:8080/q/health/ready

Configuration

# Add your application.properties here, if applicable.
quarkus.vertx.prefer-native-transport=true
quarkus.http.so-reuse-port=true
quarkus.http.tcp-quick-ack=true
quarkus.http.tcp-cork=true
quarkus.http.tcp-fast-open=true

## disable kafka health check
quarkus.kafka.health.enabled=false

## Logs
quarkus.log.level=DEBUG

## openapi configuration
mp.openapi.extensions.smallrye.openapi=3.0.3

## Http client  configuration
mp.messaging.outgoing.metrics.connector=smallrye-http
mp.messaging.outgoing.metrics.method=POST
mp.messaging.outgoing.metrics.url=http://localhost:9090/test

## Kafka Ingestion configuration
# mp.messaging.outgoing.metrics.connector=smallrye-kafka
# kafka.bootstrap.servers=host.docker.internal:9092
# mp.messaging.outgoing.metrics.topic=metrics
# mp.messaging.outgoing.metrics.value.serializer=org.apache.kafka.common.serialization.ByteArraySerializer

Screenshots (If applicable, add screenshots to help explain your problem.)

Environment (please complete the following information):

  • Output of uname -a or ver: Darwin 19.6.0 Darwin Kernel Version
  • Output of java -version: openjdk version “11.0.10” 2021-01-19 OpenJDK Runtime Environment AdoptOpenJDK (build 11.0.10+9) OpenJDK 64-Bit Server VM AdoptOpenJDK (build 11.0.10+9, mixed mode)
  • GraalVM version (if different from Java):
  • Quarkus version or git rev: Quarkus 1.11.1.Final
  • Build tool (ie. output of mvnw --version or gradlew --version): Apache Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)

Additional context (Add any other context about the problem here.)

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
cescoffiercommented, Feb 25, 2021

There are two levels of health checks: the one coming from the Quarkus Kafka extension and the one comings from Reactive Messaging.

To disable the checks on reactive messaging, use:

mp.messaging.outgoing.metrics.health-enabled=false

If you have multiple channels, and want to disable them globally, use:

mp.messaging.connector.smallrye-kafka.health-enabled=false
0reactions
cescoffiercommented, May 3, 2021

Closing - please reopen if it still happens. A reproducer would be really nice.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Spring-Cloud-Stream-Kafka Custom Health check not working
It looks like kafka health check is disabled in spring actuator health check. So, I managed to write the following code to enable...
Read more >
Spring Cloud Stream Kafka Binder Reference Guide
In the latter case, if the topics do not exist, the binder fails to start. ... a health indicator to check the state...
Read more >
Kafka Broker Health Tests | 6.3.x - Cloudera Documentation
This Kafka Broker health test checks that the Auditing for the Kafka Broker role is getting processed correctly and is not blocked. A...
Read more >
Confluent Metrics Reporter
The Confluent Metrics Reporter collects various metrics from an Apache Kafka® cluster. The Confluent Metrics Reporter is necessary for the Confluent Control ...
Read more >
Apache Kafka - SmallRye Reactive Messaging
The Kafka connector disables the Kafka auto commit if not explicitly enabled. ... deprecated - During the readiness health check, the connector connects...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found