[ 
https://issues.apache.org/jira/browse/PHOENIX-5116?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16756898#comment-16756898
 ] 

Lars Hofhansl edited comment on PHOENIX-5116 at 1/31/19 5:49 AM:
-----------------------------------------------------------------

Instead of the table, I had to check the plan whether it has salted key-ranges, 
and in that case remove those from consideration in choosing a plan. I think 
it's fine to leak a bit of internals to the plan chooser due to the nature of 
heuristic plan selection.

The change as such should be very uncontroversial. I can LocalIndexIT and 
DistinctPrefixFilterIT, both pass now.


was (Author: lhofhansl):
Instead of the table, I had to check the plan whether it has salted key-ranges, 
and in that case remove those from consideration in choosing a plan.

The change as such should be very uncontroversial. I can LocalIndexIT and 
DistinctPrefixFilterIT, both pass now.

> DistinctPrefixFilterIT fails.
> -----------------------------
>
>                 Key: PHOENIX-5116
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-5116
>             Project: Phoenix
>          Issue Type: Task
>            Reporter: Lars Hofhansl
>            Priority: Major
>         Attachments: 5116.txt
>
>
> Caused by this scenario outlined on PHOENIX-5109:
> {quote}
> This just does not end. Now there's a special case for the following:
> *     compound key of VARCHAR
> *     SELECT DISTINCT <prefix of the key>
> *     Salting is enabled
> *     There is a local index on an unrelated column
> Now Phoenix selects a full local index scan, which is heuristically less 
> efficient... I think.
> The problem is that there are cases where a plan for a salted table 
> nonetheless gets a key range that is not salted - does not have the salt 
> range in it. That throws the logic off in this case.
> {quote}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to