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

ASF GitHub Bot commented on HAWQ-850:
-------------------------------------

GitHub user zhangh43 opened a pull request:

    https://github.com/apache/incubator-hawq/pull/745

    HAWQ-850. Planner supports refineCachedPlan interface.

    in PBE(prepare bind execution) cases, plan will be cached, and only be 
generated once in postgres.
    But in HAWQ since resource is dynamic or elastic, the plan maybe changed 
during the different execution of PBE. Also, the file split allocation result 
which is stored in plan is dynamically too, so the split-vseg mapping may also 
be changed.
    
    For example, We call a plpgsql function which do "insert into t select * 
from t".
    in Prepare we cache the plan, with fixed split-vseg mapping(e.g. 10 
blocks), but after insert, there would be 20 blocks so the old  split-vseg 
mapping is invalid. We need to update it. Also when we call this function again 
and again, the data size of t may request more resource to handle it than the 
first call, so we should recalculate the entire plan with the new vseg number.
    
    This function is implemented in a interface called refineCachedPlan.
    [Link to Jira](https://issues.apache.org/jira/browse/HAWQ-850)

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/zhangh43/incubator-hawq hawq850

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/incubator-hawq/pull/745.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #745
    
----
commit ee4cdf7a694ccf62f0548dd0a52ddb874f9976dd
Author: hzhang2 <zhanghuan...@163.com>
Date:   2016-06-22T06:36:51Z

    HAWQ-850. Planner supports refineCachedPlan interface.

----


> Planner supports refineCachedPlan interface.
> --------------------------------------------
>
>                 Key: HAWQ-850
>                 URL: https://issues.apache.org/jira/browse/HAWQ-850
>             Project: Apache HAWQ
>          Issue Type: Sub-task
>          Components: Core
>            Reporter: Hubert Zhang
>            Assignee: Hubert Zhang
>
> in PBE(prepare bind execution) cases, plan will be cached, and only be 
> generated once in postgres.
> But in HAWQ since resource is dynamic or elastic, the plan maybe changed 
> during the different execution of PBE. Also, the file split allocation result 
> which is stored in plan is dynamically too, so the split-vseg mapping may 
> also be changed.
> For example, We call a plpgsql function which do "insert into t select * from 
> t".
> in Prepare we cache the plan, with fixed split-vseg mapping(e.g. 10 blocks), 
> but after insert, there would be 20 blocks so the old  split-vseg mapping is 
> invalid. We need to update it. Also when we call this function again and 
> again, the data size of t may request more resource to handle it than the 
> first call, so we should recalculate the entire plan with the new vseg number.
> This function is implemented in a interface called refineCachedPlan.



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

Reply via email to