Uploaded image for project: 'Log4j 2'
  1. Log4j 2
  2. LOG4J2-2062

Add possibility of sending the key of a message to Kafka using KafkaAppender

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.9.0, 2.9.1
    • 2.10.0
    • Appenders
    • None

    Description

      When using the KafkaAppender the KafkaManager only sends the value of a message to a Kafka topic.

      It could be useful to be able to assign a value to the key of that message via configuration instead of having it null.

      Check https://github.com/apache/logging-log4j2/blob/master/log4j-core/src/main/java/org/apache/logging/log4j/core/appender/mom/kafka/KafkaManager.java#L99

      Updated with link to the PR: https://github.com/apache/logging-log4j2/pull/112

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            mikaelstaldal Mikael Ståldal
            Flowcont Jorge Sanchez
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment