avro-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bridger Howell (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (AVRO-2090) Improve encode/decode time for SpecificRecord using code generation
Date Wed, 11 Oct 2017 13:29:00 GMT

    [ https://issues.apache.org/jira/browse/AVRO-2090?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16200271#comment-16200271
] 

Bridger Howell commented on AVRO-2090:
--------------------------------------

This looks like a really good idea. If I have some free time, I'll try to help with code review.

> Improve encode/decode time for SpecificRecord using code generation
> -------------------------------------------------------------------
>
>                 Key: AVRO-2090
>                 URL: https://issues.apache.org/jira/browse/AVRO-2090
>             Project: Avro
>          Issue Type: Improvement
>          Components: java
>            Reporter: Raymie Stata
>         Attachments: customcoders.md
>
>
> Compared to GenericRecords, SpecificRecords offer type-safety plus the performance of
traditional getters/setters/instance variables.  But these are only beneficial to Java code
accessing those records.  SpecificRecords inherit serialization and deserialization code from
GenericRecords, which is dynamic and thus slow (in fact, benchmarks show that serialization
and deserialization is _slower_ for SpecificRecord than for GenericRecord).
> This patch extends record.vm to generate custom, higher-performance encoder and decoder
functions for SpecificRecords.  We've run a public benchmark showing that the new code reduces
serialization time by 2/3 and deserialization time by close to 50%.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message