MINOR KAFKA-7705 : update java doc for delivery.timeout.ms#6000
Merged
hachikuji merged 2 commits intoapache:trunkfrom Dec 12, 2018
Merged
MINOR KAFKA-7705 : update java doc for delivery.timeout.ms#6000hachikuji merged 2 commits intoapache:trunkfrom
hachikuji merged 2 commits intoapache:trunkfrom
Conversation
Contributor
|
LGTM. @hachikuji Please help review this minor doc change. |
ijuma
reviewed
Dec 9, 2018
| * props.put("bootstrap.servers", "localhost:9092"); | ||
| * props.put("acks", "all"); | ||
| * props.put("delivery.timeout.ms", 30000); | ||
| * props.put("delivery.timeout.ms", 30001); |
Member
There was a problem hiding this comment.
I think we should actually make this example simpler. Most of these configs don't need to be changed. We could change the example to be something like:
* Properties props = new Properties();
* props.put("bootstrap.servers", "localhost:9092");
* props.put("acks", "all");
*
* try (Producer<String, String> producer = new KafkaProducer<>(props, new StringSerializer(), new StringSerializer())) {
* for (int i = 0; i < 100; i++)
* producer.send(new ProducerRecord<>("my-topic", Integer.toString(i), Integer.toString(i)));
* }What do you think?
Contributor
Author
There was a problem hiding this comment.
Okay, I'll update it.
Contributor
Author
|
@ijuma could you review this again? thanks. |
hachikuji
approved these changes
Dec 12, 2018
hachikuji
pushed a commit
that referenced
this pull request
Dec 12, 2018
The example in the producer's javadoc contained an inconsistent value for `delivery.timeout.ms`. This patch removes the inconsistent config and several unnecessary overrides in order to simplify the example. Reviewers: huxi <huxi_2b@hotmail.com>, Ismael Juma <ismael@juma.me.uk>, Jason Gustafson <jason@confluent.io>
pengxiaolong
pushed a commit
to pengxiaolong/kafka
that referenced
this pull request
Jun 14, 2019
…he#6000) The example in the producer's javadoc contained an inconsistent value for `delivery.timeout.ms`. This patch removes the inconsistent config and several unnecessary overrides in order to simplify the example. Reviewers: huxi <huxi_2b@hotmail.com>, Ismael Juma <ismael@juma.me.uk>, Jason Gustafson <jason@confluent.io>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
update KafkaProducer javadoc to put delivery.timeout.ms >= request.timeout.ms + linger.ms