[
https://issues.apache.org/jira/browse/PIG-2167?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13268819#comment-13268819
]
[email protected] commented on PIG-2167:
----------------------------------------------------
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/4670/#review7484
-----------------------------------------------------------
This review took a little time as I got interrupted in the middle. :)
Great job overall.
Some comments are about refactoring a little part of the code your modifying.
Let me know what you think.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/newplan/logical/optimizer/AllExpressionVisitor.java
<https://reviews.apache.org/r/4670/#comment16557>
iterate on entries() instead
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/newplan/logical/optimizer/AllExpressionVisitor.java
<https://reviews.apache.org/r/4670/#comment16561>
All those for loops could be factored into a private
visitAll(Collection<LogicalExpressionPlan>)
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/newplan/logical/optimizer/SchemaResetter.java
<https://reviews.apache.org/r/4670/#comment16562>
same comment.
You can factor out the for loops in those methods.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/newplan/logical/relational/LOCube.java
<https://reviews.apache.org/r/4670/#comment16563>
chain all exceptions
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/newplan/logical/relational/LOCube.java
<https://reviews.apache.org/r/4670/#comment16564>
same
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/AstValidator.g
<https://reviews.apache.org/r/4670/#comment16566>
do you know if there's a way to avoid duplication across .g files?
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/LogicalPlanBuilder.java
<https://reviews.apache.org/r/4670/#comment16567>
you can make this a javadoc comment
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/LogicalPlanBuilder.java
<https://reviews.apache.org/r/4670/#comment16568>
this is not affected to anything. Is it intended?
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/LogicalPlanBuilder.java
<https://reviews.apache.org/r/4670/#comment16569>
same comment. I guess it is intended, but it looks strange. If the
constructor has side effect, maybe there should be another way
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/LogicalPlanBuilder.java
<https://reviews.apache.org/r/4670/#comment16776>
add the name of the duplicate in the error message
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/LogicalPlanGenerator.g
<https://reviews.apache.org/r/4670/#comment16777>
please add some comments to explain what you're doing here
http://svn.apache.org/repos/asf/pig/trunk/test/org/apache/pig/test/TestCubeOperator.java
<https://reviews.apache.org/r/4670/#comment16778>
you van now use mock.Storage() for those tests.
see PIG-2650
http://svn.apache.org/repos/asf/pig/trunk/test/org/apache/pig/test/TestCubeOperator.java
<https://reviews.apache.org/r/4670/#comment16779>
Use the message part of the assert statement to ensure a good error message
when it fails.
Tuple t = it.next()
assertTrue(expected+" contains "+t, expected.contains(t))
- Julien
On 2012-04-30 04:05:03, Prasanth_J wrote:
bq.
bq. -----------------------------------------------------------
bq. This is an automatically generated e-mail. To reply, visit:
bq. https://reviews.apache.org/r/4670/
bq. -----------------------------------------------------------
bq.
bq. (Updated 2012-04-30 04:05:03)
bq.
bq.
bq. Review request for pig and Dmitriy Ryaboy.
bq.
bq.
bq. Summary
bq. -------
bq.
bq. This is a review board for https://issues.apache.org/jira/browse/PIG-2167
bq.
bq.
bq. This addresses bug PIG-2167.
bq. https://issues.apache.org/jira/browse/PIG-2167
bq.
bq.
bq. Diffs
bq. -----
bq.
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/newplan/logical/optimizer/AllExpressionVisitor.java
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/newplan/logical/optimizer/SchemaResetter.java
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/newplan/logical/relational/LOCube.java
PRE-CREATION
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/newplan/logical/relational/LogicalRelationalNodesVisitor.java
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/newplan/logical/visitor/ProjectStarExpander.java
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/AliasMasker.g
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/AstPrinter.g
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/AstValidator.g
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/LogicalPlanBuilder.java
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/LogicalPlanGenerator.g
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/QueryLexer.g
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/src/org/apache/pig/parser/QueryParser.g
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/test/org/apache/pig/parser/TestLexer.pig
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/test/org/apache/pig/parser/TestLogicalPlanGenerator.java
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/test/org/apache/pig/parser/TestParser.pig
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/test/org/apache/pig/parser/TestQueryLexer.java
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/test/org/apache/pig/parser/TestQueryParser.java
1325115
bq.
http://svn.apache.org/repos/asf/pig/trunk/test/org/apache/pig/test/TestCubeOperator.java
PRE-CREATION
bq.
bq. Diff: https://reviews.apache.org/r/4670/diff
bq.
bq.
bq. Testing
bq. -------
bq.
bq. Unit tests: All passed
bq.
bq. Pre-commit tests: All passed
bq. ant clean test-commit
bq.
bq.
bq. Thanks,
bq.
bq. Prasanth_J
bq.
bq.
> CUBE operation in Pig
> ---------------------
>
> Key: PIG-2167
> URL: https://issues.apache.org/jira/browse/PIG-2167
> Project: Pig
> Issue Type: New Feature
> Reporter: Dmitriy V. Ryaboy
> Assignee: Dmitriy V. Ryaboy
> Labels: gsoc2012, mentor
> Attachments: PIG-2167.1.patch, PIG-2167.2.patch, PIG-2167.3.patch,
> Pig-Cubing-Performance.png
>
>
> Computing aggregates over a cube of several dimensions is a common operation
> in data warehousing.
> The standard SQL syntax is "GROUP relation BY dim1, dim2, dim3 WITH CUBE" --
> which in addition to all dim1-2-3, produces aggregations for just dim1, just
> dim1 and dim2, etc. NULL is generally used to represent "all".
> A presentation by Arnab Nandi describes how one might implement efficient
> cubing in Map-Reduce here: http://pdf.cx/44wrk
> We can start with the naive solution which only works for algebraic measures,
> and work up from there.
> This is a candidate project for Google summer of code 2012. More information
> about the program can be found at
> https://cwiki.apache.org/confluence/display/PIG/GSoc2012
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira