You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@kudu.apache.org by "Will Berkeley (Code Review)" <ge...@cloudera.org> on 2016/06/03 14:46:20 UTC

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Will Berkeley has uploaded a new change for review.

  http://gerrit.cloudera.org:8080/3298

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................

KUDU-1446 Consider data types in predicate evaluation order

This patch enhances SelectivityRank() in column_predicate.cc to account for
column type. Predicate type dominates column type for the sort, and a predicate
on a column of a small type will sort before a predicate on a column of larger
(or variable-size) type.

Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
---
M src/kudu/common/column_predicate.cc
1 file changed, 31 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/98/3298/1
-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 1
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Posted by "Todd Lipcon (Code Review)" <ge...@cloudera.org>.
Todd Lipcon has submitted this change and it was merged.

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................


KUDU-1446 Consider data types in predicate evaluation order

This patch enhances SelectivityRank() in column_predicate.cc to account for
column type. Predicate type dominates column type for the sort, and a predicate
on a column of a small type will sort before a predicate on a column of larger
(or variable-size) type.

It also adds a small test for selectivity comparison.

Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Reviewed-on: http://gerrit.cloudera.org:8080/3298
Tested-by: Kudu Jenkins
Reviewed-by: Todd Lipcon <to...@apache.org>
---
M src/kudu/common/column_predicate-test.cc
M src/kudu/common/column_predicate.cc
2 files changed, 49 insertions(+), 5 deletions(-)

Approvals:
  Todd Lipcon: Looks good to me, approved
  Kudu Jenkins: Verified



-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 4
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
Gerrit-Reviewer: Will Berkeley <wd...@gmail.com>

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Posted by "Will Berkeley (Code Review)" <ge...@cloudera.org>.
Will Berkeley has posted comments on this change.

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................


Patch Set 3:

> (1 comment)

Done.

-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
Gerrit-Reviewer: Will Berkeley <wd...@gmail.com>
Gerrit-HasComments: No

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Posted by "Will Berkeley (Code Review)" <ge...@cloudera.org>.
Will Berkeley has uploaded a new patch set (#2).

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................

KUDU-1446 Consider data types in predicate evaluation order

This patch enhances SelectivityRank() in column_predicate.cc to account for
column type. Predicate type dominates column type for the sort, and a
predicate on a column of a small type will sort before a predicate on a
column of larger (or variable-size) type.

Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
---
M src/kudu/common/column_predicate.cc
1 file changed, 31 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/98/3298/2
-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 2
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>
Gerrit-Reviewer: Kudu Jenkins

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Posted by "Todd Lipcon (Code Review)" <ge...@cloudera.org>.
Todd Lipcon has posted comments on this change.

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................


Patch Set 2:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/3298/2/src/kudu/common/column_predicate.cc
File src/kudu/common/column_predicate.cc:

Line 360:   rank *= 10;
how about:

return rank * (kLargestTypeSize + 1) + predicate.column().type_info()->size();

and then this list doesn't have to be manually maintained?


-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 2
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
Gerrit-HasComments: Yes

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Posted by "Todd Lipcon (Code Review)" <ge...@cloudera.org>.
Todd Lipcon has posted comments on this change.

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................


Patch Set 3: Code-Review+2

-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
Gerrit-Reviewer: Will Berkeley <wd...@gmail.com>
Gerrit-HasComments: No

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Posted by "Kudu Jenkins (Code Review)" <ge...@cloudera.org>.
Kudu Jenkins has posted comments on this change.

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................


Patch Set 2:

Build Started http://104.196.14.100/job/kudu-gerrit/1733/

-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 2
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-HasComments: No

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Posted by "Kudu Jenkins (Code Review)" <ge...@cloudera.org>.
Kudu Jenkins has posted comments on this change.

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................


Patch Set 3:

Build Started http://104.196.14.100/job/kudu-gerrit/1735/

-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
Gerrit-HasComments: No

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Posted by "Todd Lipcon (Code Review)" <ge...@cloudera.org>.
Todd Lipcon has posted comments on this change.

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................


Patch Set 2:

Also a unit test here would be nice (isn't there a test somewhere that tests the sorting?)

-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 2
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
Gerrit-HasComments: No

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Posted by "Will Berkeley (Code Review)" <ge...@cloudera.org>.
Will Berkeley has posted comments on this change.

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................


Patch Set 3:

(1 comment)

> Also a unit test here would be nice (isn't there a test somewhere
 > that tests the sorting?)

I didn't see a test for it. I added a little one.

http://gerrit.cloudera.org:8080/#/c/3298/2/src/kudu/common/column_predicate.cc
File src/kudu/common/column_predicate.cc:

Line 360: } // anonymous namespace
> how about:
Done.


-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>
Gerrit-Reviewer: Will Berkeley <wd...@gmail.com>
Gerrit-HasComments: Yes

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Posted by "Will Berkeley (Code Review)" <ge...@cloudera.org>.
Hello Kudu Jenkins,

I'd like you to reexamine a change.  Please visit

    http://gerrit.cloudera.org:8080/3298

to look at the new patch set (#3).

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................

KUDU-1446 Consider data types in predicate evaluation order

This patch enhances SelectivityRank() in column_predicate.cc to account for
column type. Predicate type dominates column type for the sort, and a predicate
on a column of a small type will sort before a predicate on a column of larger
(or variable-size) type.

It also adds a small test for selectivity comparison.

Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
---
M src/kudu/common/column_predicate-test.cc
M src/kudu/common/column_predicate.cc
2 files changed, 49 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/98/3298/3
-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>

[kudu-CR] KUDU-1446 Consider data types in predicate evaluation order

Posted by "Kudu Jenkins (Code Review)" <ge...@cloudera.org>.
Kudu Jenkins has posted comments on this change.

Change subject: KUDU-1446 Consider data types in predicate evaluation order
......................................................................


Patch Set 1:

Build Started http://104.196.14.100/job/kudu-gerrit/1732/

-- 
To view, visit http://gerrit.cloudera.org:8080/3298
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I9c3388876035cb494fdb2c0e1f17698f089fdf72
Gerrit-PatchSet: 1
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Will Berkeley <wd...@gmail.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-HasComments: No