From d9029ef69e87cbd5d31fd8617d4ed0c9e8b9ccae Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Thu, 17 May 2018 16:08:38 +0200 Subject: [PATCH] Fix documentation of spring.kafka.producer.batch-size Closes gh-13127 --- .../boot/autoconfigure/kafka/KafkaProperties.java | 5 +++-- .../src/main/asciidoc/appendix-application-properties.adoc | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/kafka/KafkaProperties.java b/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/kafka/KafkaProperties.java index 356c9fbcd51..9b7e0f56c97 100644 --- a/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/kafka/KafkaProperties.java +++ b/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/kafka/KafkaProperties.java @@ -1,5 +1,5 @@ /* - * Copyright 2012-2016 the original author or authors. + * Copyright 2012-2018 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -444,7 +444,8 @@ public class KafkaProperties { private String acks; /** - * Number of records to batch before sending. + * Default batch size in bytes. A small batch size will make batching less common + * and may reduce throughput (a batch size of zero disables batching entirely). */ private Integer batchSize; diff --git a/spring-boot-docs/src/main/asciidoc/appendix-application-properties.adoc b/spring-boot-docs/src/main/asciidoc/appendix-application-properties.adoc index 5b04948ff8b..e6976e8ae61 100644 --- a/spring-boot-docs/src/main/asciidoc/appendix-application-properties.adoc +++ b/spring-boot-docs/src/main/asciidoc/appendix-application-properties.adoc @@ -917,7 +917,7 @@ content into your application; rather pick only the properties that you need. spring.kafka.listener.concurrency= # Number of threads to run in the listener containers. spring.kafka.listener.poll-timeout= # Timeout in milliseconds to use when polling the consumer. spring.kafka.producer.acks= # Number of acknowledgments the producer requires the leader to have received before considering a request complete. - spring.kafka.producer.batch-size= # Number of records to batch before sending. + spring.kafka.producer.batch-size= # Default batch size in bytes. spring.kafka.producer.bootstrap-servers= # Comma-delimited list of host:port pairs to use for establishing the initial connection to the Kafka cluster. spring.kafka.producer.buffer-memory= # Total bytes of memory the producer can use to buffer records waiting to be sent to the server. spring.kafka.producer.client-id= # Id to pass to the server when making requests; used for server-side logging.