Skip to content

Commit bf73869

Browse files
committed
Document state updates for consumers
There can be state updates for the consume connection and also for the server-side offset tracking connection (if activated).
1 parent 829b337 commit bf73869

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/main/java/com/rabbitmq/stream/ConsumerBuilder.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,12 @@ public interface ConsumerBuilder {
129129
/**
130130
* Add {@link Resource.StateListener}s to the consumer.
131131
*
132+
* <p>A consumer uses one connection for consuming and another connection for server-side offset
133+
* tracking (if activated by setting a name with {@link #name(String)}). A {@link
134+
* Resource.StateListener} receives state updates for both connections, so a consumer can still be
135+
* consuming messages after it receives a {@link Resource.State#RECOVERING} state update, as the
136+
* update may be related to the offset tracking connection.
137+
*
132138
* @param listeners listeners
133139
* @return this builder instance
134140
* @since 1.3.0

0 commit comments

Comments
 (0)