crunch-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Micah Whitacre (JIRA)" <>
Subject [jira] [Commented] (CRUNCH-401) Make it possible to override AvroMode.REFLECTs ReaderWriterFactory
Date Tue, 27 May 2014 15:37:01 GMT


Micah Whitacre commented on CRUNCH-401:

    * The name of the configuration parameter that tracks which reflection
    * factory to use.
-   *
-   * @deprecated as of 0.9.0; use AvroMode.REFLECT.override(ReaderWriterFactory)
   public static final String REFLECT_DATA_FACTORY_CLASS = "crunch.reflectdatafactory";

The deprecation removal seemed odd since there are other places where stuff is deprecated
and says to use that constant.  Should we keep it and instead suggest they use override +
the configuration?

Also are you intending this to go into master or the 0.8 code stream?  

> Make it possible to override AvroMode.REFLECTs ReaderWriterFactory
> ------------------------------------------------------------------
>                 Key: CRUNCH-401
>                 URL:
>             Project: Crunch
>          Issue Type: Bug
>          Components: Core
>            Reporter: Josh Wills
>            Assignee: Josh Wills
>         Attachments: CRUNCH-401.patch
> After struggling with some Scrunch issues w/respect to Avro reflection, I discovered
that it wasn't possible for me to override the Java ReflectDataFactory that is associated
with AvroMode.REFLECT like I can for AvroMode.SPECIFIC and AvroMode.GENERIC.
> I put together a patch that enables us to overwrite the Reader/Writer behavior associated
with AvroMode.REFLECT globally, and demonstrated how to use this behavior to fix a Scrunch
bug where Scala's byte array class wasn't getting properly serialized on reflection in Scrunch.

This message was sent by Atlassian JIRA

View raw message