Giter Site home page Giter Site logo

Comments (5)

elnur avatar elnur commented on July 25, 2024 7

I'm at 1.2.0.RELEASE and still seeing all this excessive logging.

from spring-cloud-stream-binder-kafka.

mbogoevici avatar mbogoevici commented on July 25, 2024

Hi @wblancqu,

thanks for reporting this. We'll get this for our next point release. Until we get to it, as per the usual, we encourage users to contribute with any improvements they see fit :).

from spring-cloud-stream-binder-kafka.

ltalhouarne avatar ltalhouarne commented on July 25, 2024

@wblancqu,

We are using the same strategy for health checking our applications.

However, I don't believe the KafkaConsumer API allows for passing the aforementioned boolean that the AbstractConfig utilizes.

In the meantime, we've decided to change the logging level for the ConsumerConfig as well as the ProducerConfig to ERROR. We lose the initial logging on boot up but our logs don't get clustered for each health check.

logging.level.org.apache.kafka.clients.consumer.ConsumerConfig=ERROR      
logging.level.org.apache.kafka.clients.producer.ProducerConfig=ERROR

from spring-cloud-stream-binder-kafka.

blancqua avatar blancqua commented on July 25, 2024

Hi @ltalhouarne,

Thanks for your reply. We did indeed the same trick:

log4j2.yml:

Configuration:
packages: "org.whatever"
Appenders:
Console:
name: console
target: SYSTEM_OUT
ThresholdFilter:
level: debug
onMatch: ALLOW
PatternLayout:
pattern: '%d [%p] [%t] %c{1.} %m%n'
Loggers:
# Avoid superfluous logging due to health checks
Logger:
- name: org.apache.kafka
additivity: false
level: warn
AppenderRef:
- ref: console
- name: kafka
additivity: false
level: warn
AppenderRef:
- ref: console
- name: org.springframework.cloud.config.client
additivity: false
level: warn
AppenderRef:
- ref: console
Root:
level: info
AppenderRef:
- ref: console

from spring-cloud-stream-binder-kafka.

laur89 avatar laur89 commented on July 25, 2024

If you still want the ConsumerConfig to how up in logs upon startup, you could decrease log level just after kafka binder is started: https://gist.github.com/laur89/bef122a936996d83554353e0601916ae

from spring-cloud-stream-binder-kafka.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.