Flume receives an error when a single message is too large

org.apache.kafka.common.errors.RecordTooLargeException: The request included a message larger than the max message size the server will accept.

Java client tuning: Max_ REQUEST_ SIZE_ CONFIG

Kafka server side adjustment: message. Max. bytes = 2147483640 is close to the max of int, because the maximum range of this value is int

Special note: after the parameter is adjusted, it has no effect on the created topic
adjust the parameter of the created topic: set to the maximum integer value of 2147483647

bin/kafka-configs.sh --zookeeper localhost:2181  --alter --topic topic_name   --add-config  max.message.bytes=2147483647

Problem solving
 

Read More: