single active consumer is not consuming messages #412
-
Hi there! Got an issue when enabling a single active consumer in a stream consumers.
Consumers:
when i launch my producer, everything is ok:
when i launch my consumers, the single active consumer works fine, but the consumption process doesn't:
Console doesn't print eveything else. The message above occurs in every consumer. Did i forget something in my code ? Thanks in advance |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
@blendereru the API You need to store and offset before querying it. See Here is a working example:
|
Beta Was this translation helpful? Give feedback.
-
Thanks! |
Beta Was this translation helpful? Give feedback.
@blendereru the API
streamSystem.QueryOffset
could raise an exception if the offset does not exist.( maybe it is time to implement #370 )
You need to store and offset before querying it. See
await consumer.StoreOffset(context.Offset).ConfigureAwait(false);
Here is a working example: