You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "kirktrue (via GitHub)" <gi...@apache.org> on 2023/05/11 14:52:45 UTC

[GitHub] [kafka] kirktrue commented on a diff in pull request #12685: KAFKA-14945: Add Serializer#serializeToByteBuffer() to reduce memory copying

kirktrue commented on code in PR #12685:
URL: https://github.com/apache/kafka/pull/12685#discussion_r1191281659


##########
clients/src/main/java/org/apache/kafka/clients/producer/KafkaProducer.java:
##########
@@ -1383,9 +1386,13 @@ private ClusterResourceListeners configureClusterResourceListeners(Serializer<K>
      * can be used (the partition is then calculated by built-in
      * partitioning logic).
      */
-    private int partition(ProducerRecord<K, V> record, byte[] serializedKey, byte[] serializedValue, Cluster cluster) {

Review Comment:
   Lest my eyes deceive me, this is just formatting, correct?



##########
clients/src/main/java/org/apache/kafka/clients/producer/Partitioner.java:
##########
@@ -31,13 +34,27 @@ public interface Partitioner extends Configurable, Closeable {
      *
      * @param topic The topic name
      * @param key The key to partition on (or null if no key)
-     * @param keyBytes The serialized key to partition on( or null if no key)
+     * @param keyBytes The serialized key to partition on(or null if no key)

Review Comment:
   nit: Can we change:
   
   `The serialized key to partition on(or null if no key)`
   
   to
   
   `The serialized key to partition on (or null if no key)`



-- 
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-unsubscribe@kafka.apache.org

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