@@ -1669,7 +1669,7 @@ private ConsumerRecords<K, V> doPoll() {
1669
1669
}
1670
1670
TopicPartition next = this .batchIterator .next ();
1671
1671
List <ConsumerRecord <K , V >> subBatch = Objects .requireNonNull (this .lastBatch ).records (next );
1672
- records = new ConsumerRecords <>(Collections .singletonMap (next , subBatch ));
1672
+ records = new ConsumerRecords <>(Collections .singletonMap (next , subBatch ), Map . of () );
1673
1673
if (!this .batchIterator .hasNext ()) {
1674
1674
this .batchIterator = null ;
1675
1675
}
@@ -1911,7 +1911,7 @@ private void checkIdle() {
1911
1911
long idleEventInterval2 = idleEventInterval ;
1912
1912
long now = System .currentTimeMillis ();
1913
1913
if (!this .receivedSome ) {
1914
- idleEventInterval2 *= this .containerProperties .getIdleBeforeDataMultiplier ();
1914
+ idleEventInterval2 = ( long ) ( idleEventInterval2 * this .containerProperties .getIdleBeforeDataMultiplier () );
1915
1915
}
1916
1916
if (now > this .lastReceive + idleEventInterval2
1917
1917
&& now > this .lastAlertAt + idleEventInterval2 ) {
@@ -2649,7 +2649,7 @@ private boolean checkImmediatePause(Iterator<ConsumerRecord<K, V>> iterator) {
2649
2649
tp -> new ArrayList <ConsumerRecord <K , V >>()).add (next );
2650
2650
}
2651
2651
if (!remaining .isEmpty ()) {
2652
- this .remainingRecords = new ConsumerRecords <>(remaining );
2652
+ this .remainingRecords = new ConsumerRecords <>(remaining , Map . of () );
2653
2653
return true ;
2654
2654
}
2655
2655
}
@@ -2950,7 +2950,7 @@ private void invokeErrorHandlerBySingleRecord(FailedRecordTuple<K, V> failedReco
2950
2950
tp -> new ArrayList <>()).add (cRecord );
2951
2951
}
2952
2952
if (!records .isEmpty ()) {
2953
- this .remainingRecords = new ConsumerRecords <>(records );
2953
+ this .remainingRecords = new ConsumerRecords <>(records , Map . of () );
2954
2954
this .pauseForPending = true ;
2955
2955
}
2956
2956
}
@@ -2996,7 +2996,7 @@ private void invokeErrorHandler(final ConsumerRecord<K, V> cRecord,
2996
2996
}
2997
2997
}
2998
2998
if (!records .isEmpty ()) {
2999
- this .remainingRecords = new ConsumerRecords <>(records );
2999
+ this .remainingRecords = new ConsumerRecords <>(records , Map . of () );
3000
3000
this .pauseForPending = true ;
3001
3001
}
3002
3002
}
@@ -3614,7 +3614,7 @@ public void acknowledge(int index) {
3614
3614
tp -> new ArrayList <>()).add (record );
3615
3615
}
3616
3616
if (!offsetsToCommit .isEmpty ()) {
3617
- processAcks (new ConsumerRecords <>(offsetsToCommit ));
3617
+ processAcks (new ConsumerRecords <>(offsetsToCommit , Map . of () ));
3618
3618
}
3619
3619
this .partial = index ;
3620
3620
}
@@ -3644,7 +3644,7 @@ public void nack(int index, Duration sleep) {
3644
3644
newRecords .computeIfAbsent (new TopicPartition (cRecord .topic (), cRecord .partition ()),
3645
3645
tp -> new LinkedList <>()).add (cRecord );
3646
3646
}
3647
- processAcks (new ConsumerRecords <K , V >(newRecords ));
3647
+ processAcks (new ConsumerRecords <K , V >(newRecords , Map . of () ));
3648
3648
}
3649
3649
3650
3650
@ Override
@@ -3727,7 +3727,7 @@ private void removeRevocationsFromPending(Collection<TopicPartition> partitions)
3727
3727
if (!remainingParts .isEmpty ()) {
3728
3728
Map <TopicPartition , List <ConsumerRecord <K , V >>> trimmed = new LinkedHashMap <>();
3729
3729
remainingParts .forEach (part -> trimmed .computeIfAbsent (part , tp -> remaining .records (tp )));
3730
- ListenerConsumer .this .remainingRecords = new ConsumerRecords <>(trimmed );
3730
+ ListenerConsumer .this .remainingRecords = new ConsumerRecords <>(trimmed , Map . of () );
3731
3731
}
3732
3732
else {
3733
3733
ListenerConsumer .this .remainingRecords = null ;
0 commit comments