Ratandeep Ratti created PIG-4501:
------------------------------------

             Summary: Write API for Avro[Tuple|Map|Bag]wrapper classes is broken
                 Key: PIG-4501
                 URL: https://issues.apache.org/jira/browse/PIG-4501
             Project: Pig
          Issue Type: Bug
            Reporter: Ratandeep Ratti


{{AvroTupleWrapper}}, {{AvroMapWrapper}} and {{AvroBagWrapper}} expose write 
APIs but their implementation is broken. 

For instance, we can do 
{code}
Tuple t = TupleFactory.newInstnace().newTuple(1);
t.set(0, 0);
avroTupleWrapper.set(0, t);
avroTupleWrapper.get(0);  
{code}
The last line will (in most cases) fail depending upon what the avro schema is 
for the 0th element.

I'm attaching a patch which highlights this more concretely. The patch only 
shows failures in AvroTupleWrapper but similar problems exist in corresponding 
Map and Bag classes



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to