Thanks for the help. In my situation I'm reading Avro payloads out of Kafka so I can't use the Avro data file to detect the written schema. I'll look into tracking the written schema in an alternate manner.
On Wed, Aug 27, 2014 at 5:50 PM, Doug Cutting <cutt...@apache.org> wrote: > On Wed, Aug 27, 2014 at 11:08 AM, Micah Whitacre <mkwhita...@gmail.com> > wrote: > > We are reading with a BufferedBinaryDecoder and using the new schema as > both > > the written and reader schema because the written schema is not preserved > > with the payload so it is not easy to retrieve. > > > > My questions are: > > 1. Is the change we made to add a new defaulted union truly non-passive? > > Adding the new union field changes the format for how instances are > written, even those that have a null value for this new field. (A > union is written as an int indicating the selected schema, then an > instance of that schema.) > > > 2. Is there a workaround so I can continue to evolve my schema? > > To permit schema evolution, you must pass the schema used to write > when reading. Avro's data file format and RPC take care of this. If > you're writing Avro data to some other container then you need to do > this yourself. > > Doug >