-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Description
In what version(s) of Spring for Apache Kafka are you seeing this issue?
For example:
3.2
Describe the bug
-
When using
AbstractConsumerSeekAware
in a multi-group listener scenario, there are cases where the number of registered callbacks differs from the number of discovered callbacks. Let's consider the examples below. -
Case 1:
- Topic partitions: 1
- Consumer groups: 2 (group1, group2)
- Registered callbacks: 2 (group1 thread callback and group2 thread callback)
- Discovered callbacks: 1 (either group1 thread callback or group2 thread callback — only one callback exists assigned to topic partition 0)
-
Case 2 - with concurrency:
- Topic partitions: 2
- Consumer groups: 2 (group1, group2)
- Concurrency: 2 per group
- Registered callbacks: 4
- group1-0 thread callback, group1-1 thread callback, group2-0 thread callback, group2-1 thread callback
- Discovered callbacks: 2
- 1 thread assigned to partition 0 and 1 thread assigned to partition 1 (uncertain whether they belong to group1 or group2 threads)
Expected behavior
- The number of discovered callbacks should be equal to the number of registered callbacks.
Sample