brandboat commented on code in PR #22468:
URL: https://github.com/apache/kafka/pull/22468#discussion_r3381285766


##########
clients/src/test/java/org/apache/kafka/clients/consumer/ConsumerRecordsTest.java:
##########
@@ -180,6 +182,69 @@ public void testRecordsAreImmutable() {
         assertEquals(0, emptyRecords.count());
     }
 
+    @Test
+    @SuppressWarnings("deprecation")

Review Comment:
   nit:
   ```suggestion
       @SuppressWarnings("removal")
   ```
   
   Otherwise we see warning messages below in the build process:
   
   ```
   > Task :clients:compileTestJava
   
/Users/brandboat/Code/kafka/kafka/clients/src/test/java/org/apache/kafka/clients/consumer/ConsumerRecordsTest.java:199:
 warning: [removal] 
<K,V>ConsumerRecords(Map<TopicPartition,List<ConsumerRecord<K,V>>>) in 
ConsumerRecords has been deprecated and marked for removal
               ConsumerRecords<Integer, String> consumerRecords = new 
ConsumerRecords<>(records);
                                                                  ^
     where K,V are type-variables:
       K extends Object declared in class ConsumerRecords
       V extends Object declared in class ConsumerRecords
   
/Users/brandboat/Code/kafka/kafka/clients/src/test/java/org/apache/kafka/clients/consumer/ConsumerRecordsTest.java:211:
 warning: [removal] 
<K,V>ConsumerRecords(Map<TopicPartition,List<ConsumerRecord<K,V>>>) in 
ConsumerRecords has been deprecated and marked for removal
               assertTrue(new 
ConsumerRecords<>(records).nextOffsets().isEmpty());
                          ^
     where K,V are type-variables:
       K extends Object declared in class ConsumerRecords
       V extends Object declared in class ConsumerRecords
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to