Re: enum schema evolution

2023-05-05 Thread KV 59
as well. Obviously this is not the case. since symbol "S7" is not present in schema1 and also it has no default value defined, On Fri, May 5, 2023 at 7:37 AM Brennan Vincent wrote: > Which one is the writer and which is the reader? > > Sent from my iPhone > > On May

enum schema evolution

2023-05-04 Thread KV 59
Hi, I see that that java Avro compatibility check doesn't work as per specification for enum schema evolution. I have a the following schema { > "type" : "record", > "name" : "TestEnumRec", > "namespace" : "com.five9.avro.enum.test", > "fields" : [ { > "name" : "enumType", >

Converting SpecificRecord to GenericRecord of different Schema Versions

2021-12-05 Thread KV 59
Hi All, Here is my situation, I have a SpecificRecord for a Schema S and I want to convert it into a GenericRecord of a compatible Schema T (It is an older version of S). I have seen many such examples but all strategies point to serializing the SpecificRecord to either bytes or JSON and

Setting a null value to field with default value

2021-03-23 Thread KV 59
Hi, I have a schema defined as below > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > *{ "type" : "record", "name" : "DefRecord", "namespace" : > "com.test.ns1", "doc" : "Message", "fields" : [ {"name" : > "providerId","type" : { "type" : "string",

Schema Evolution Removing fields

2020-07-07 Thread KV 59
> > Hi, I'm trying to remove a field which is required in the old schema (which is by default) long field1; and want to remove the field in the updated schema I made it optional and nullable union {null, long} field1 = null; Now the new schema can read the objects from the old schema

Schema Evolution which one to use (SchemaValidator or SchemaCompatibility)

2020-07-07 Thread KV 59
Hi, There are two implementations to czech schema evolution, 1. org.apache.avro.SchemaValidator (and it's implementations) 2. org.apache.avro.SchemaCompatibility The SchemaCompatibility provides more information about incompatibilities. While the SchemaValidator just says compatible or not. My

Re: SchemaValidator vs SchemaCompatibility

2020-07-07 Thread KV 59
chema, mapping to the > name worksheet1. This will not work, as I understand it, because aliases > are a property of the schema, not the data, and so the reader will be > unaware of the alias declared on the writer schema. I expect what you need > to do is instead declare an alias in the reader schema on

SchemaValidator vs SchemaCompatibility

2020-07-06 Thread KV 59
Which is the right class to use to check compatibility? I'm using Avro 1.9.2 and I'm trying to check the compatibility for the fo schemas using the SchemaCompatibility and I can't figure what the issue is and why it says incompatible Reader Schemas - > { >

Re: union schema evolution

2019-08-01 Thread KV 59
r.java:170) > at > org.apache.avro.generic.GenericDatumReader.read(GenericDatumReader.java:151) > at > org.apache.avro.generic.GenericDatumReader.read(GenericDatumReader.java:144) Why can't the union resolution return a null if it cannot find an appropriate or a branch of the same type. I