On Fri, Oct 11, 2013 at 9:24 AM, Youssef Hatem
<[email protected]> wrote:
> Since a string can be null, will Avro (Java implementation) encapsulate Bar 
> in a union? (i.e. type of Bar field will be regarded as ["null", "string"]).

If you want to intermix nulls and strings then you need to explicitly
use a union.  If null is passed as a string then a
NullPointerException is thrown.

> Another question, what happens when we want to deserialize a null string?

A serialized string is never null.  It may be an empty string.

Doug

Reply via email to