kafka-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Guozhang Wang (JIRA)" <j...@apache.org>
Subject [jira] [Created] (KAFKA-8584) Allow "bytes" type to generated a ByteBuffer rather than byte arrays
Date Fri, 21 Jun 2019 22:49:00 GMT
Guozhang Wang created KAFKA-8584:
------------------------------------

             Summary: Allow "bytes" type to generated a ByteBuffer rather than byte arrays
                 Key: KAFKA-8584
                 URL: https://issues.apache.org/jira/browse/KAFKA-8584
             Project: Kafka
          Issue Type: Sub-task
            Reporter: Guozhang Wang


Right now in the RPC definition, type {{bytes}} would be translated into {{byte[]}} in generated
Java code. However, for some requests like ProduceRequest#partitionData, the underlying type
would better be a ByteBuffer rather than a byte array.

One proposal is to add an additional boolean tag {{useByteBuffer}} for {{bytes}} type, which
by default is false; when set to {{true}} set the corresponding field to generate {{ByteBuffer}}
instead of {{[]byte}}. 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message