You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hive.apache.org by Jonathan Natkins <na...@cloudera.com> on 2011/01/25 09:25:46 UTC

Review Request: HIVE-1735. Extend Explode UDTF to handle Maps

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/354/
-----------------------------------------------------------

Review request for hive.


Summary
-------

Review request for HIVE-1735.


This addresses bug HIVE-1735.
    https://issues.apache.org/jira/browse/HIVE-1735


Diffs
-----

  ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTFExplode.java d1e7def 
  ql/src/test/queries/clientnegative/udtf_explode_not_supported1.q PRE-CREATION 
  ql/src/test/queries/clientnegative/udtf_explode_not_supported2.q PRE-CREATION 
  ql/src/test/queries/clientnegative/udtf_explode_not_supported3.q PRE-CREATION 
  ql/src/test/queries/clientnegative/udtf_explode_not_supported4.q PRE-CREATION 
  ql/src/test/queries/clientpositive/udf_explode.q f5c0323 
  ql/src/test/queries/clientpositive/udtf_explode.q f5c0323 
  ql/src/test/results/clientnegative/udtf_explode_not_supported1.q.out PRE-CREATION 
  ql/src/test/results/clientnegative/udtf_explode_not_supported2.q.out PRE-CREATION 
  ql/src/test/results/clientnegative/udtf_explode_not_supported3.q.out PRE-CREATION 
  ql/src/test/results/clientnegative/udtf_explode_not_supported4.q.out PRE-CREATION 
  ql/src/test/results/clientpositive/udf_explode.q.out 511732f 
  ql/src/test/results/clientpositive/udtf_explode.q.out 6702c3f 

Diff: https://reviews.apache.org/r/354/diff


Testing
-------

Manual and automated testing


Thanks,

Jonathan


Re: Review Request: HIVE-1735. Extend Explode UDTF to handle Maps

Posted by Jonathan Natkins <na...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/354/
-----------------------------------------------------------

(Updated 2011-01-31 21:19:47.368551)


Review request for hive.


Summary
-------

Review request for HIVE-1735.


This addresses bug HIVE-1735.
    https://issues.apache.org/jira/browse/HIVE-1735


Diffs (updated)
-----

  ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTFExplode.java d1e7def 
  ql/src/test/queries/clientnegative/udtf_explode_not_supported1.q PRE-CREATION 
  ql/src/test/queries/clientnegative/udtf_explode_not_supported2.q PRE-CREATION 
  ql/src/test/queries/clientnegative/udtf_explode_not_supported3.q PRE-CREATION 
  ql/src/test/queries/clientnegative/udtf_explode_not_supported4.q PRE-CREATION 
  ql/src/test/queries/clientpositive/udf_explode.q f5c0323 
  ql/src/test/queries/clientpositive/udtf_explode.q f5c0323 
  ql/src/test/results/clientnegative/udtf_explode_not_supported1.q.out PRE-CREATION 
  ql/src/test/results/clientnegative/udtf_explode_not_supported2.q.out PRE-CREATION 
  ql/src/test/results/clientnegative/udtf_explode_not_supported3.q.out PRE-CREATION 
  ql/src/test/results/clientnegative/udtf_explode_not_supported4.q.out PRE-CREATION 
  ql/src/test/results/clientpositive/udf_explode.q.out 511732f 
  ql/src/test/results/clientpositive/udtf_explode.q.out 6702c3f 

Diff: https://reviews.apache.org/r/354/diff


Testing
-------

Manual and automated testing


Thanks,

Jonathan


Re: Review Request: HIVE-1735. Extend Explode UDTF to handle Maps

Posted by Amareshwari Sriramadasu <am...@apache.org>.

> On 2011-01-25 13:19:29, Carl Steinbach wrote:
> > ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTFExplode.java, line 106
> > <https://reviews.apache.org/r/354/diff/1/?file=10207#file10207line106>
> >
> >     Under what conditions are map and array null? Is this code path exercised by any of the tests? Just trying to wrap my head around what this means. I'd prefer to see this changed to an assertion if map and array should never be null.

explode_null.q is failing because of this assert change. So, this is needed to handle if the map or array object is null in some of the rows. 


- Amareshwari


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/354/#review154
-----------------------------------------------------------


On 2011-01-31 21:19:47, Jonathan Natkins wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/354/
> -----------------------------------------------------------
> 
> (Updated 2011-01-31 21:19:47)
> 
> 
> Review request for hive.
> 
> 
> Summary
> -------
> 
> Review request for HIVE-1735.
> 
> 
> This addresses bug HIVE-1735.
>     https://issues.apache.org/jira/browse/HIVE-1735
> 
> 
> Diffs
> -----
> 
>   ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTFExplode.java d1e7def 
>   ql/src/test/queries/clientnegative/udtf_explode_not_supported1.q PRE-CREATION 
>   ql/src/test/queries/clientnegative/udtf_explode_not_supported2.q PRE-CREATION 
>   ql/src/test/queries/clientnegative/udtf_explode_not_supported3.q PRE-CREATION 
>   ql/src/test/queries/clientnegative/udtf_explode_not_supported4.q PRE-CREATION 
>   ql/src/test/queries/clientpositive/udf_explode.q f5c0323 
>   ql/src/test/queries/clientpositive/udtf_explode.q f5c0323 
>   ql/src/test/results/clientnegative/udtf_explode_not_supported1.q.out PRE-CREATION 
>   ql/src/test/results/clientnegative/udtf_explode_not_supported2.q.out PRE-CREATION 
>   ql/src/test/results/clientnegative/udtf_explode_not_supported3.q.out PRE-CREATION 
>   ql/src/test/results/clientnegative/udtf_explode_not_supported4.q.out PRE-CREATION 
>   ql/src/test/results/clientpositive/udf_explode.q.out 511732f 
>   ql/src/test/results/clientpositive/udtf_explode.q.out 6702c3f 
> 
> Diff: https://reviews.apache.org/r/354/diff
> 
> 
> Testing
> -------
> 
> Manual and automated testing
> 
> 
> Thanks,
> 
> Jonathan
> 
>


Re: Review Request: HIVE-1735. Extend Explode UDTF to handle Maps

Posted by Carl Steinbach <ca...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/354/#review154
-----------------------------------------------------------



ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTFExplode.java
<https://reviews.apache.org/r/354/#comment319>

    For the sake of performance most UDFs follow the convention of allocating the forwardObj array once (and yes, I think this is gross). I recommend that you do this:
    
    private final Object[] forwardArrayObj = new Object[1];
    private final Object[] forwardMapObj = new Object[2];
    



ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTFExplode.java
<https://reviews.apache.org/r/354/#comment318>

    Under what conditions are map and array null? Is this code path exercised by any of the tests? Just trying to wrap my head around what this means. I'd prefer to see this changed to an assertion if map and array should never be null.


- Carl


On 2011-01-25 00:25:46, Jonathan Natkins wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/354/
> -----------------------------------------------------------
> 
> (Updated 2011-01-25 00:25:46)
> 
> 
> Review request for hive.
> 
> 
> Summary
> -------
> 
> Review request for HIVE-1735.
> 
> 
> This addresses bug HIVE-1735.
>     https://issues.apache.org/jira/browse/HIVE-1735
> 
> 
> Diffs
> -----
> 
>   ql/src/java/org/apache/hadoop/hive/ql/udf/generic/GenericUDTFExplode.java d1e7def 
>   ql/src/test/queries/clientnegative/udtf_explode_not_supported1.q PRE-CREATION 
>   ql/src/test/queries/clientnegative/udtf_explode_not_supported2.q PRE-CREATION 
>   ql/src/test/queries/clientnegative/udtf_explode_not_supported3.q PRE-CREATION 
>   ql/src/test/queries/clientnegative/udtf_explode_not_supported4.q PRE-CREATION 
>   ql/src/test/queries/clientpositive/udf_explode.q f5c0323 
>   ql/src/test/queries/clientpositive/udtf_explode.q f5c0323 
>   ql/src/test/results/clientnegative/udtf_explode_not_supported1.q.out PRE-CREATION 
>   ql/src/test/results/clientnegative/udtf_explode_not_supported2.q.out PRE-CREATION 
>   ql/src/test/results/clientnegative/udtf_explode_not_supported3.q.out PRE-CREATION 
>   ql/src/test/results/clientnegative/udtf_explode_not_supported4.q.out PRE-CREATION 
>   ql/src/test/results/clientpositive/udf_explode.q.out 511732f 
>   ql/src/test/results/clientpositive/udtf_explode.q.out 6702c3f 
> 
> Diff: https://reviews.apache.org/r/354/diff
> 
> 
> Testing
> -------
> 
> Manual and automated testing
> 
> 
> Thanks,
> 
> Jonathan
> 
>