Skip to content

KAFKA-7509: Logging unused configs as DEBUG rather than WARN#5867

Closed
rhauch wants to merge 1 commit intoapache:trunkfrom
rhauch:kafka-7509-b
Closed

KAFKA-7509: Logging unused configs as DEBUG rather than WARN#5867
rhauch wants to merge 1 commit intoapache:trunkfrom
rhauch:kafka-7509-b

Conversation

@rhauch
Copy link
Copy Markdown
Contributor

@rhauch rhauch commented Nov 1, 2018

The KafkaProducer, KafkaConsumer, and KafkaAdminClient all call config.logUnused() to log all of the unused configurations. These can be very misleading, because some conventional configuration properties for custom interceptors, key or value (de)serializers, metrics reporters, and partitioner are not actually defined by ConfigDefs and are thus all considered unused and logged as warnings.

Also, some client applications (such as Connect) do not determine the subset of properties that can be passed to one of these clients, since there are these custom extensions. This causes extra properties to be logged as warnings, which is concerning for new users.

These unused configurations should be logged at DEBUG level instead to reduce the number of unexpected warnings in many client application logs.

Backporting

This is a usability improvement that affects only this particular log message. As such, it may or may not be something that should be backported. Advice from committers would be appreciated.

Committer Checklist (excluded from commit message)

  • Verify design and implementation
  • Verify test coverage and CI build status
  • Verify documentation (including upgrade notes)

The KafkaProducer, KafkaConsumer, and KafkaAdminClient all call `config.logUnused()` to log all of the unused configurations. These can be very misleading, because some conventional configuration properties for custom interceptors, key or value (de)serializers, metrics reporters, and partitioner are not actually defined by ConfigDefs and are thus all considered unused and logged as warnings.

Also, some client applications (such as Connect) do not determine the subset of properties that can be passed to one of these clients, since there are these custom extensions. This causes extra properties to be logged as warnings, which is concerning for new users.

These unused configurations should be logged at DEBUG level instead to reduce the number of unexpected warnings in many client application logs.
@rhauch
Copy link
Copy Markdown
Contributor Author

rhauch commented Nov 1, 2018

Supersedes #5802

@rhauch
Copy link
Copy Markdown
Contributor Author

rhauch commented Nov 1, 2018

retest this please

@rhauch
Copy link
Copy Markdown
Contributor Author

rhauch commented Nov 2, 2018

See KAFKA-7509 for discussion. This approach is to invasive, since it is beneficial for clients to log unused messages in custom applications.

Closing this without merging, and instead favoring #5876 that simply filters the properties before passing them to the clients.

@rhauch rhauch closed this Nov 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant