[
https://issues.apache.org/jira/browse/GORA-309?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Lewis John McGibbney updated GORA-309:
--------------------------------------
Description:
Right now in Avro 1.7.6 we can add data to our data bean(s) as follows[0].
User user1 = new User();
user1.setName("Alyssa");
user1.setFavoriteNumber(256);
// Leave favorite color null
// Alternate constructor
User user2 = new User("Ben", 7, "red");
// Construct via builder
User user3 = User.newBuilder()
.setName("Charlie")
.setFavoriteColor("blue")
.setFavoriteNumber(null)
.build();
In current gora-compiler code we DO NOT shadow this behavior. This issue should
enable the flexibility of populating objects as shown in the three use cases
above.
[0] http://avro.apache.org/docs/current/gettingstartedjava.html#Creating+Users
was:
Right now in Avro 1.7.6 we can add data to our data bean(s) as follows[0].
User user1 = new User();
user1.setName("Alyssa");
user1.setFavoriteNumber(256);
// Leave favorite color null
// Alternate constructor
User user2 = new User("Ben", 7, "red");
// Construct via builder
User user3 = User.newBuilder()
.setName("Charlie")
.setFavoriteColor("blue")
.setFavoriteNumber(null)
.build();
In current GORA_94 gora-compiler code we DO NOT shadow this behavior. This
issue should ensure that we do.
[0] http://avro.apache.org/docs/current/gettingstartedjava.html#Creating+Users
> Align data object definition with Avro 1.7.X specification
> ----------------------------------------------------------
>
> Key: GORA-309
> URL: https://issues.apache.org/jira/browse/GORA-309
> Project: Apache Gora
> Issue Type: Improvement
> Components: gora-compiler, gora-core
> Affects Versions: 0.4
> Reporter: Lewis John McGibbney
> Fix For: 0.7
>
>
> Right now in Avro 1.7.6 we can add data to our data bean(s) as follows[0].
> User user1 = new User();
> user1.setName("Alyssa");
> user1.setFavoriteNumber(256);
> // Leave favorite color null
> // Alternate constructor
> User user2 = new User("Ben", 7, "red");
> // Construct via builder
> User user3 = User.newBuilder()
> .setName("Charlie")
> .setFavoriteColor("blue")
> .setFavoriteNumber(null)
> .build();
> In current gora-compiler code we DO NOT shadow this behavior. This issue
> should enable the flexibility of populating objects as shown in the three use
> cases above.
> [0] http://avro.apache.org/docs/current/gettingstartedjava.html#Creating+Users
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)