Skip to content

Use structured format for Kafka SampleProducer  #369

@shnplr

Description

@shnplr

The examples/kafka/src/main/java/io/cloudevents/examples/kafka/SampleProducer.java indicates a structured event but delivers a binary event.

// Configure the CloudEventSerializer to emit events as json structured events
props.put(ProducerConfig.VALUE_SERIALIZER_CLASS_CONFIG, CloudEventSerializer.class);
props.put(CloudEventSerializer.ENCODING_CONFIG, Encoding.BINARY);
props.put(CloudEventSerializer.EVENT_FORMAT_CONFIG, JsonFormat.CONTENT_TYPE);

Should this be Encoding.STRUCTURED?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions