Aniruddha Navare created KAFKA-19279:
----------------------------------------
Summary: DefaultMessageFormatter is inaccessible as it's
package-private class
Key: KAFKA-19279
URL: https://issues.apache.org/jira/browse/KAFKA-19279
Project: Kafka
Issue Type: Bug
Components: tools
Affects Versions: 3.9.0
Reporter: Aniruddha Navare
As per [upgrade-notes|
https://github.com/apache/kafka/blob/ec70c4436210b7578777739091e365b03c69946f/docs/upgrade.html#L259],
it has been told as below
{code:java}
kafka.tools.DefaultMessageFormatter{code}
class was removed.
Please use the
{code:java}
org.apache.kafka.tools.consumer.DefaultMessageFormatter{code}
class instead.
Now
{code:java}
org.apache.kafka.tools.consumer.DefaultMessageFormatter{code}
is package-private class which means, we can't directly use it as below
{code:java}
private val defaultFormatter: DefaultMessageFormatter = new
DefaultMessageFormatter {code}
It throws error as
{code:java}
Symbol DefaultMessageFormatter is inaccessible from this place {code}
Due ot this, we can't use other member variable `printHeaders`.
This is happened when we upgraded kafka-tools from 3.4.1 to 3.9.0 version.
Need help in this regarding.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)