Skip to content

Commit 6812d25

Browse files
authored
Improve EventStreamResponseHandler.Builder.onError method to mention the callback may be called multiple time, similarly to the exceptionOccurred method (#6340)
1 parent 6d791e0 commit 6812d25

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"type": "documentation",
3+
"category": "AWS SDK for Java v2",
4+
"contributor": "",
5+
"description": "Improve EventStreamResponseHandler.Builder.onError method to mention the callback may be called multiple time, similarly to the exceptionOccurred method"
6+
}

core/aws-core/src/main/java/software/amazon/awssdk/awscore/eventstream/EventStreamResponseHandler.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,8 @@ interface Builder<ResponseT, EventT, SubBuilderT> {
9494
SubBuilderT onResponse(Consumer<ResponseT> responseConsumer);
9595

9696
/**
97-
* Callback to invoke in the event on an error.
97+
* Callback to invoke in the event on an error. The {@link Consumer#accept(Object)} method may be called multiple times
98+
* during the lifecycle of a request if automatic retries are enabled.
9899
*
99100
* @param consumer Callback that will process any error that occurs.
100101
* @return This builder for method chaining.

0 commit comments

Comments
 (0)