Commit 37b9311be93191aa52307ef16aed6f36bf4838a7

Authored by Andrii Shvaika
1 parent 2407c868

Empty partitions

... ... @@ -85,7 +85,12 @@ public abstract class AbstractTbQueueConsumerTemplate<R, T extends TbQueueMsg> i
85 85 subscribed = true;
86 86 }
87 87
88   - List<R> records = doPoll(durationInMillis);
  88 + List<R> records;
  89 + if (partitions.isEmpty()) {
  90 + records = Collections.emptyList();
  91 + } else {
  92 + records = doPoll(durationInMillis);
  93 + }
89 94 if (!records.isEmpty()) {
90 95 List<T> result = new ArrayList<>(records.size());
91 96 records.forEach(record -> {
... ...