Question
HCL Technologies
NL
Last activity: 15 Jul 2022 2:14 EDT
KAFKA Custom Header
We wanted to send custom header,
Header Key |
Value |
Sample JAVA code for header value |
encryptedVersion |
Array of byte buffer integer |
ByteBuffer.allocate(4).putInt(1).array() |
We went through the help, Pega provides below options for header in KAFKA Data Set.
- Data format Key-Value Pair - We can add Key Name and Value for that which is expected to be String.
- Data format Custom – Here we can have custom class used which will return byte array. Then PEGA will add header key as “Pega-Custom” and the Key value returned by the Custom Header Serde class.
We are in need to add our own header key and custom header value.