Copilot commented on code in PR #20141:
URL: https://github.com/apache/kafka/pull/20141#discussion_r2517096659


##########
core/src/main/scala/kafka/server/ReplicaManager.scala:
##########
@@ -1109,10 +1109,12 @@ class ReplicaManager(val config: KafkaConfig,
         } catch {
           case e@ (_: UnknownTopicOrPartitionException |
                    _: NotLeaderOrFollowerException |
-                   _: OffsetOutOfRangeException |
                    _: PolicyViolationException |
                    _: KafkaStorageException) =>
             (topicPartition, LogDeleteRecordsResult(-1L, -1L, Some(e)))
+          case e: OffsetOutOfRangeException =>
+            debug("Error processing delete records operation on partition 
%s".format(topicPartition), e)

Review Comment:
   [nitpick] The error message format is inconsistent with the existing error 
logging pattern on line 1119. Consider using string interpolation (s\"...\") 
instead of .format() for consistency with modern Scala conventions and improved 
readability.
   ```suggestion
               debug(s"Error processing delete records operation on partition 
$topicPartition", e)
   ```



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