[jira] [Commented] (AVRO-1626) Missing lang/csharp/src/apache/perf/app.config
[ https://issues.apache.org/jira/browse/AVRO-1626?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15511560#comment-15511560 ] Simon Woodford commented on AVRO-1626: -- Copying the app.config file from src/apache/codegen to src/apache/perf allows this to compile with (apparently) no ill effect. Once I'm convinced that it's the right thing to do, I'll submit a patch > Missing lang/csharp/src/apache/perf/app.config > -- > > Key: AVRO-1626 > URL: https://issues.apache.org/jira/browse/AVRO-1626 > Project: Avro > Issue Type: Bug > Components: csharp >Reporter: Niels Basjes > > This error is output during the build > {code} > Target _CopyAppConfigFile: > /usr/lib/mono/4.5/Microsoft.Common.targets: error : Cannot copy > /home/nbasjes/avro/lang/csharp/src/apache/perf/app.config to > /home/nbasjes/avro/lang/csharp/build/perf/Release/Avro.perf.exe.config, as > the source file doesn't exist. > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Resolved] (AVRO-1915) AvroTypeException decoding from earlier schema version
[ https://issues.apache.org/jira/browse/AVRO-1915?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ryan Blue resolved AVRO-1915. - Resolution: Not A Problem Thanks for letting us know you got past this. I'm going to resolve this issue. > AvroTypeException decoding from earlier schema version > -- > > Key: AVRO-1915 > URL: https://issues.apache.org/jira/browse/AVRO-1915 > Project: Avro > Issue Type: Bug > Components: java >Affects Versions: 1.7.7 >Reporter: NPE > > We have two services which communicate with one another by sending > JSON-encoded Avro-based messages over Kafka. We want to update the schema > for messages sent from service A to service B by adding an additional string > field with a default value of "" (empty string). We have tested by initially > adding the updated schema to service B (the reader) and continuing to send > messages in the older format from service A (the writer). > Simplified example of old schema (some fields omitted): > {code} > { > "type": "record", > "name": "Envelope", > "fields": [{ > "name": "appId", > "type": "string" > }, { > "name": "time", > "type": "long" > }, { > "name": "type", > "type": "string" > }, { > "name": "payload", > "type": [{ > "type": "record", > "name": "MessagePayload", > "fields": [{ > "name": "context", > "type": { > "type": "record", > "name": "PayloadContext", > "fields": [{ > "name": "source", > "type": "string" > }, { > "name": "requestId", > "type": "string" > }] > } > }, { > "name": "content", > "type": "string" > }, { > "name": "contentType", > "type": "string" > }] > }] > }] > } > {code} > Simplified example of new schema (some fields omitted): > {code} > { > "type": "record", > "name": "Envelope", > "fields": [{ > "name": "appId", > "type": "string" > }, { > "name": "time", > "type": "long" > }, { > "name": "type", > "type": "string" > }, { > "name": "payload", > "type": [{ > "type": "record", > "name": "MessagePayload", > "fields": [{ > "name": "context", > "type": { > "type": "record", > "name": "PayloadContext", > "fields": [{ > "name": "source", > "type": "string" > }, { > "name": "requestId", > "type": "string" > }, { > "name": "newField", > "type": "string", > "default": "" > }] > } > }, { > "name": "content", > "type": "string" > }, { > "name": "contentType", > "type": "string" > }] > }] > }] > } > {code} > Our understanding was that the reader, with the newer schema, should be able > to parse messages sent with the older given the default value for the missing > field; however, we are getting the following exception: > {code} > org.apache.avro.AvroTypeException: Expected string. Got END_OBJECT > {code} > Are we missing something here? -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (AVRO-1582) Json serialization of nullable fileds and fields with default values improvement.
[ https://issues.apache.org/jira/browse/AVRO-1582?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15509865#comment-15509865 ] Sean Busbey commented on AVRO-1582: --- I've increased this from 'minor' to 'major' priority, but I believe the current blocker on it getting accepted is that we need a contributor that's willing to finish things up. > Json serialization of nullable fileds and fields with default values > improvement. > - > > Key: AVRO-1582 > URL: https://issues.apache.org/jira/browse/AVRO-1582 > Project: Avro > Issue Type: Improvement > Components: java >Affects Versions: 1.8.0 >Reporter: Zoltan Farkas > Attachments: AVRO-1582-PATCH > > > Currently serializing a nullable field of type union like: > "type" : ["null","some type"] > when serialized as JSON results in: > "field":{"some type":"value"} > when it could be: > "field":"value" > Also fields that equal the the default value can be omitted from the > serialized data. This is possible because the reader will have the writer's > schema and can infer the field values. This reduces the size of the json > messages. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (AVRO-1582) Json serialization of nullable fileds and fields with default values improvement.
[ https://issues.apache.org/jira/browse/AVRO-1582?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Sean Busbey updated AVRO-1582: -- Priority: Major (was: Minor) > Json serialization of nullable fileds and fields with default values > improvement. > - > > Key: AVRO-1582 > URL: https://issues.apache.org/jira/browse/AVRO-1582 > Project: Avro > Issue Type: Improvement > Components: java >Affects Versions: 1.8.0 >Reporter: Zoltan Farkas > Attachments: AVRO-1582-PATCH > > > Currently serializing a nullable field of type union like: > "type" : ["null","some type"] > when serialized as JSON results in: > "field":{"some type":"value"} > when it could be: > "field":"value" > Also fields that equal the the default value can be omitted from the > serialized data. This is possible because the reader will have the writer's > schema and can infer the field values. This reduces the size of the json > messages. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (AVRO-1582) Json serialization of nullable fileds and fields with default values improvement.
[ https://issues.apache.org/jira/browse/AVRO-1582?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15509283#comment-15509283 ] Marius Soutier commented on AVRO-1582: -- Can we increase priority on this? It'd make Avro adoption in existing JSON environments much easier. > Json serialization of nullable fileds and fields with default values > improvement. > - > > Key: AVRO-1582 > URL: https://issues.apache.org/jira/browse/AVRO-1582 > Project: Avro > Issue Type: Improvement > Components: java >Affects Versions: 1.8.0 >Reporter: Zoltan Farkas >Priority: Minor > Attachments: AVRO-1582-PATCH > > > Currently serializing a nullable field of type union like: > "type" : ["null","some type"] > when serialized as JSON results in: > "field":{"some type":"value"} > when it could be: > "field":"value" > Also fields that equal the the default value can be omitted from the > serialized data. This is possible because the reader will have the writer's > schema and can infer the field values. This reduces the size of the json > messages. -- This message was sent by Atlassian JIRA (v6.3.4#6332)