[jira] [Commented] (AVRO-2723) Avro Java: Obtaining default field values for POJO objects with ReflectData

2020-04-30 Thread Hudson (Jira)


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

Hudson commented on AVRO-2723:
--

SUCCESS: Integrated in Jenkins build AvroJava #853 (See 
[https://builds.apache.org/job/AvroJava/853/])
AVRO-2723: Extend ReflectData to get default values for fields from (github: 
[https://github.com/apache/avro/commit/cfb6a12a5eba4ebcef1e04f53b19728d6da9aa5c])
* (edit) lang/java/avro/src/main/java/org/apache/avro/reflect/ReflectData.java
* (edit) 
lang/java/avro/src/main/java/org/apache/avro/util/internal/JacksonUtils.java
* (edit) 
lang/java/avro/src/test/java/org/apache/avro/reflect/TestReflectData.java


> Avro Java: Obtaining default field values for POJO objects with ReflectData
> ---
>
> Key: AVRO-2723
> URL: https://issues.apache.org/jira/browse/AVRO-2723
> Project: Apache Avro
>  Issue Type: New Feature
>  Components: java
>Affects Versions: 1.9.1
>Reporter: Andy Le
>Assignee: Andy Le
>Priority: Critical
> Fix For: 1.10.0
>
> Attachments: Screen Shot 2020-03-08 at 16.13.29.png
>
>
> Hi guys,
>  
> I've got a simple app using Avro Reflection:
>  
> {code:java}
> public class App {
>   public static void main(String[] args) {
> testReflection();
>   }
>   static class User {
> public String first = "Andy";
> public String last = "Le";
>   }
>   static void testReflection(){
> // get the reflected schema for packets
> Schema schema = ReflectData.AllowNull.get().getSchema(User.class);
> System.out.println(schema.toString(true));
>   }
> {code}
> The output on console will be:
> {noformat}
> {
>   "type" : "record",
>   "name" : "User",
>   "namespace" : "App",
>   "fields" : [ {
> "name" : "first",
> "type" : [ "null", "string" ],
> "default" : null
>   }, {
> "name" : "last",
> "type" : [ "null", "string" ],
> "default" : null
>   } ]
> }
> {noformat}
>  
> As you can see, there's no default values for fields. Would you please tell 
> me how to obtain such values?
> Thank you.
>  
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Resolved] (AVRO-2723) Avro Java: Obtaining default field values for POJO objects with ReflectData

2020-04-30 Thread Doug Cutting (Jira)


 [ 
https://issues.apache.org/jira/browse/AVRO-2723?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Doug Cutting resolved AVRO-2723.

Fix Version/s: 1.10.0
 Assignee: Andy Le
   Resolution: Fixed

I committed this.  Thanks, Andy!

> Avro Java: Obtaining default field values for POJO objects with ReflectData
> ---
>
> Key: AVRO-2723
> URL: https://issues.apache.org/jira/browse/AVRO-2723
> Project: Apache Avro
>  Issue Type: New Feature
>  Components: java
>Affects Versions: 1.9.1
>Reporter: Andy Le
>Assignee: Andy Le
>Priority: Critical
> Fix For: 1.10.0
>
> Attachments: Screen Shot 2020-03-08 at 16.13.29.png
>
>
> Hi guys,
>  
> I've got a simple app using Avro Reflection:
>  
> {code:java}
> public class App {
>   public static void main(String[] args) {
> testReflection();
>   }
>   static class User {
> public String first = "Andy";
> public String last = "Le";
>   }
>   static void testReflection(){
> // get the reflected schema for packets
> Schema schema = ReflectData.AllowNull.get().getSchema(User.class);
> System.out.println(schema.toString(true));
>   }
> {code}
> The output on console will be:
> {noformat}
> {
>   "type" : "record",
>   "name" : "User",
>   "namespace" : "App",
>   "fields" : [ {
> "name" : "first",
> "type" : [ "null", "string" ],
> "default" : null
>   }, {
> "name" : "last",
> "type" : [ "null", "string" ],
> "default" : null
>   } ]
> }
> {noformat}
>  
> As you can see, there's no default values for fields. Would you please tell 
> me how to obtain such values?
> Thank you.
>  
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (AVRO-2723) Avro Java: Obtaining default field values for POJO objects with ReflectData

2020-04-30 Thread ASF subversion and git services (Jira)


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

ASF subversion and git services commented on AVRO-2723:
---

Commit cfb6a12a5eba4ebcef1e04f53b19728d6da9aa5c in avro's branch 
refs/heads/master from Anh Le (Andy)
[ https://gitbox.apache.org/repos/asf?p=avro.git;h=cfb6a12 ]

AVRO-2723: Extend ReflectData to get default values for fields from classes and 
permit extension to compute defaults. (#842)



> Avro Java: Obtaining default field values for POJO objects with ReflectData
> ---
>
> Key: AVRO-2723
> URL: https://issues.apache.org/jira/browse/AVRO-2723
> Project: Apache Avro
>  Issue Type: New Feature
>  Components: java
>Affects Versions: 1.9.1
>Reporter: Andy Le
>Priority: Critical
> Attachments: Screen Shot 2020-03-08 at 16.13.29.png
>
>
> Hi guys,
>  
> I've got a simple app using Avro Reflection:
>  
> {code:java}
> public class App {
>   public static void main(String[] args) {
> testReflection();
>   }
>   static class User {
> public String first = "Andy";
> public String last = "Le";
>   }
>   static void testReflection(){
> // get the reflected schema for packets
> Schema schema = ReflectData.AllowNull.get().getSchema(User.class);
> System.out.println(schema.toString(true));
>   }
> {code}
> The output on console will be:
> {noformat}
> {
>   "type" : "record",
>   "name" : "User",
>   "namespace" : "App",
>   "fields" : [ {
> "name" : "first",
> "type" : [ "null", "string" ],
> "default" : null
>   }, {
> "name" : "last",
> "type" : [ "null", "string" ],
> "default" : null
>   } ]
> }
> {noformat}
>  
> As you can see, there's no default values for fields. Would you please tell 
> me how to obtain such values?
> Thank you.
>  
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [avro] zolyfarkas commented on pull request #864: [AVRO-2278] getter semantics confusing.

2020-04-30 Thread GitBox


zolyfarkas commented on pull request #864:
URL: https://github.com/apache/avro/pull/864#issuecomment-621804272


   @Fokko @RyanSkraba can you let me know what you think about the latests 
updates to this PR?



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [avro] zolyfarkas commented on pull request #869: AVRO-2822: Add toString that doesn't inline referenced schemas

2020-04-30 Thread GitBox


zolyfarkas commented on pull request #869:
URL: https://github.com/apache/avro/pull/869#issuecomment-621802979


   It would be nice to expose Schema.Names for the purpose of customizing 
schema reference resolution. 
   
   Here are the use cases I have:
   
   1) Avsc files referencing other schemas by name, declared in other avsc 
files.(without the need to rely on any specific processing order). I have 
implemented this in a [custom maven 
plugin](http://www.spf4j.org/spf4j-avro-components/maven-avro-schema-plugin/index.html)
  and had to use various hacks to get it done/ 
[see](https://github.com/zolyfarkas/spf4j/blob/master/spf4j-avro-components/maven-avro-schema-plugin/src/main/java/org/spf4j/maven/plugin/avro/avscp/SchemaCompileMojo.java#L350)
 basically use the same resolution mechanism used by the avdl+avpr.
   
   2) Custom references. ability to refer to a schema published to a repo like: 
{"$ref":"org.spf4j.demo:jaxrs-spf4j-demo-schema:0.3:2"}. For a detailed 
description 
[see](https://github.com/zolyfarkas/jaxrs-spf4j-demo/wiki/AvroReferences)
   
   Probably worthwhile to create a new JIRA for this, or a AEP? 



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




When and how should we remove lang/py3?

2020-04-30 Thread Michael Smith
 Previous emails on this list have discussed the "why" questions. But when
and how should we go about it? Could 1.10 be the last avro release to
include avro-python3? This would allow us to play a little less ticket
tennis with folks reporting bugs (can you reproduce this in "the other"
python library?) and focus all our effort into one python implementation.

What do you think?


[jira] [Created] (AVRO-2824) avrogen.exe tool requires unsupported .Net Core 2.2 runtime

2020-04-30 Thread Arturas Kuznecovas (Jira)
Arturas Kuznecovas created AVRO-2824:


 Summary: avrogen.exe tool requires unsupported .Net Core 2.2 
runtime
 Key: AVRO-2824
 URL: https://issues.apache.org/jira/browse/AVRO-2824
 Project: Apache Avro
  Issue Type: Improvement
  Components: tools
Affects Versions: 1.9.2
Reporter: Arturas Kuznecovas


After installing NuGet package Apache.Avro.Tools and trying to run the avrogen 
i got a message that 2.2 runtime is required i only had 3.1 runtime installed.

.Net Core 2.2 is end of life, tool should be upgraded to depend on 2.1 or 3.1 
LTS runtimes, preferably the latter.

[https://dotnet.microsoft.com/download/dotnet-core]



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [avro] tjwp commented on pull request #628: AVRO-2535: Add Ruby support for enum defaults

2020-04-30 Thread GitBox


tjwp commented on pull request #628:
URL: https://github.com/apache/avro/pull/628#issuecomment-621789200


   Looks like the build is currently failing due to an issue with C# 
dependencies.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [avro] masatana commented on pull request #865: AVRO-2814: Add __version__ to __init__.py (PEP396)

2020-04-30 Thread GitBox


masatana commented on pull request #865:
URL: https://github.com/apache/avro/pull/865#issuecomment-621652418


   Thanks @kojiromike !



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org