public interface HeaderConverter extends org.apache.kafka.common.Configurable, Closeable
Modifier and Type | Method and Description |
---|---|
org.apache.kafka.common.config.ConfigDef |
config()
Configuration specification for this set of header converters.
|
byte[] |
fromConnectHeader(String topic,
String headerKey,
Schema schema,
Object value)
|
SchemaAndValue |
toConnectHeader(String topic,
String headerKey,
byte[] value)
Convert the header name and byte array value into a
Header object. |
SchemaAndValue toConnectHeader(String topic, String headerKey, byte[] value)
Header
object.topic
- the name of the topic for the record containing the headerheaderKey
- the header's key; may not be nullvalue
- the header's raw value; may be nullSchemaAndValue
; may not be nullbyte[] fromConnectHeader(String topic, String headerKey, Schema schema, Object value)
topic
- the name of the topic for the record containing the headerheaderKey
- the header's key; may not be nullschema
- the schema for the header's value; may be nullvalue
- the header's value to convert; may be nullorg.apache.kafka.common.config.ConfigDef config()