Skip to content

    Configuring maximum message size limit for Kafka

    In some cases, you may need to configure the message size limit for Kafka when restoring data. To configure the message size limit, you need to modify the message.max.bytes property in the Kafka configuration.

    You can set the message.max.bytes property in a Restore:

    apiVersion: kannika.io/v1alpha
    kind: Restore
    metadata:
    name: restore
    spec:
    source: storage
    sink: kafka
    sinkAdditionalProps:
    message.max.bytes: "10485760" # must be a string (quoted)
    config:
    mapping:
    topic-with-large-messages:
    target: topic-with-large-messages

    For more information about configuring properties, check the section about configuring additional properties.