mjsax commented on code in PR #14626:
URL: https://github.com/apache/kafka/pull/14626#discussion_r1412530967


##########
streams/src/main/java/org/apache/kafka/streams/state/internals/RocksDBVersionedStore.java:
##########
@@ -266,75 +269,28 @@ public VersionedRecord<byte[]> get(final Bytes key, final 
long asOfTimestamp) {
         return null;
     }
 
-    public VersionedRecordIterator<byte[]> get(final Bytes key, final long 
fromTimestamp, final long toTimestamp, final boolean isAscending) {
-
-        Objects.requireNonNull(key, "key cannot be null");
+    @SuppressWarnings("unchecked")

Review Comment:
   Well, `VersionedRecordIterator<V>` takes generic `V` abutd 
`LogicalSegmentIterator ` is not specifying the type (what is a bug):
   ```
   public class LogicalSegmentIterator implements VersionedRecordIterator {
   ```
   
   Guess it should be (what will avoid the warning making the suppression 
unnecessary):
   ```
   public class LogicalSegmentIterator implements 
VersionedRecordIterator<byte[]> {
   ```
   
   What implies that `public Object next() ` should actually return `byte[]`, 
right (something I missed in my review).



-- 
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: jira-unsubscr...@kafka.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to