divijvaidya commented on code in PR #13936:
URL: https://github.com/apache/kafka/pull/13936#discussion_r1256109183


##########
storage/api/src/main/java/org/apache/kafka/server/log/remote/storage/RemoteLogSegmentMetadata.java:
##########
@@ -100,7 +100,16 @@ public RemoteLogSegmentMetadata(RemoteLogSegmentId 
remoteLogSegmentId,
         this.remoteLogSegmentId = Objects.requireNonNull(remoteLogSegmentId, 
"remoteLogSegmentId can not be null");
         this.state = Objects.requireNonNull(state, "state can not be null");
 
+        if (startOffset < 0) {
+            throw new IllegalArgumentException(
+                String.format("Unexpected start offset = %d. StartOffset for a 
remote segment cannot negative", startOffset));

Review Comment:
   No specific reason. I think it's visually more clear to read the log string 
part together instead of adding a `+`. But I don't have strong opinion about 
it. I will change to append if that's what you prefer.



-- 
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