[ 
https://issues.apache.org/jira/browse/FLINK-8354?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16593020#comment-16593020
 ] 

ASF GitHub Bot commented on FLINK-8354:
---------------------------------------

alexeyt820 opened a new pull request #6615: [FLINK-8354] [flink-connectors] Add 
ability to access and provider Kafka headers
URL: https://github.com/apache/flink/pull/6615
 
 
   
   ## What is the purpose of the change
   This changes allows to access Kafka headers in KeyedDeserializationSchema, 
and to provide Kafka headers via KeyedSerializationSchema.headers method
   
   ## Brief change log
   - Add default _headers_ method to KeyedSerializationSchema interface
   - Add default deserialize method with _headers_ argument to 
KeyedDeserializationSchema
   - Add Kafka011Fetcher to get headers from Kafka ConsumerRecord and provide 
them as parameter KeyedDeserializationSchema
   - Modify FlinkKafkaProducer011 to request _headers_ from 
KeyedSerializationSchema and add them to ProducerRecord.
   
   ## Verifying this change
   
   This change added tests and can be verified as follows:
     - *Added integration test *Kafka011ITCase.testHeaders* to verify that we 
can produce headers and consume them
   
   ## Does this pull request potentially affect one of the following parts:
   
     - Dependencies (does it add or upgrade a dependency): (no)
     - The public API, i.e., is any changed class annotated with 
`@Public(Evolving)`: (yes)
     - The serializers: (no)
     - The runtime per-record code paths (performance sensitive): (yes)
     - Anything that affects deployment or recovery: JobManager (and its 
components), Checkpointing, Yarn/Mesos, ZooKeeper: (no)
     - The S3 file system connector: (no)
   
   ## Documentation
   
     - Does this pull request introduce a new feature? (yes)
     - If yes, how is the feature documented? (JavaDocs)

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Flink Kafka connector ignores Kafka message  headers 
> -----------------------------------------------------
>
>                 Key: FLINK-8354
>                 URL: https://issues.apache.org/jira/browse/FLINK-8354
>             Project: Flink
>          Issue Type: Bug
>          Components: Kafka Connector
>         Environment: Kafka 0.11.0.0
> Flink 1.4.0
> flink-connector-kafka-0.11_2.11 
>            Reporter: Mohammad Abareghi
>            Assignee: Aegeaner
>            Priority: Major
>              Labels: pull-request-available
>
> Kafka has introduced notion of Header for messages in version 0.11.0.0  
> https://issues.apache.org/jira/browse/KAFKA-4208.
> But flink-connector-kafka-0.11_2.11 which supports kafka 0.11.0.0 ignores 
> headers when consuming kafka messages. 
> It would be useful in some scenarios, such as distributed log tracing, to 
> support message headers to FlinkKafkaConsumer011 and FlinkKafkaProducer011. 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to