Forum Stats

  • 3,872,908 Users
  • 2,266,489 Discussions


Kafka Handler

User_FR572 Member Posts: 1 Green Ribbon

I am struggling to find support for formatting/serializing my message key as JSON. This seems like such an oversight. The value payload is configurable as JSON but the key is not. While the template keyword ${primaryKeys} is interesting, it does me no good downstream. Neither does emitting primary keys as an array of property names. I require my key and value to be legitimate JSON.

I do see ${custom[]} template keyword discussed, with a note stating "It is possible to write a custom value resolver. If required, contact Oracle Support." I would prefer not to write one for something so common. Surely many others have inquired already. For example, Debezium does this -- it is an industry norm feature.

Can someone provide guidance? I am trying to avoid having to introduce Apache Kafka and/or Confluent Transforms further downstream to deal with problematic underscore-delimited keys that obviously fail JSON deserialization.

Thanks in advance!