You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@phoenix.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2018/10/12 03:11:00 UTC

[jira] [Commented] (PHOENIX-4891) An index should inherit UPDATE_CACHE_FREQUENCY setting from parent table

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

ASF GitHub Bot commented on PHOENIX-4891:
-----------------------------------------

GitHub user ChinmaySKulkarni opened a pull request:

    https://github.com/apache/phoenix/pull/363

    PHOENIX-4891: An index should inherit UPDATE_CACHE_FREQUENCY setting from parent table

    **(WIP Patch)**
    Changes in this commit:
    - When creating a local or global index on a physical table/view, we set the UPDATE_CACHE_FREQUENCY value from the base table/view
    - When altering the U_C_F value of a base table/view, we alter the same for all of its indexes
    - Since we want this property to be in sync amongst tables and their indexes, I am currently disallowing setting U_C_F when creating an index _AND_ disallowing altering this property for an index
    
    **TODO/Discussion:**
    - Handle the case of a client connecting to a server with an old timestamp of SYSCAT i.e. the upgrade code-path. Should we sync the U_C_F property amongst tables/views and their indexes? **OR**, should we instead allow altering U_C_F for indexes and make this the user's responsibility to manually do this as they need?
    - Currently, when a view is created, it inherits the U_C_F value of the base table already. Thus, indexes created on the view will also inherit the same value. However, we can later alter the U_C_F of a view (which will be propagated to its indexes). I think this is desired behavior, and a view need not have the same U_C_F value as its base table throughout its lifetime (though the index of a view should be in sync with the view), but open to other suggestions.

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

    $ git pull https://github.com/ChinmaySKulkarni/phoenix PHOENIX-4891

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

    https://github.com/apache/phoenix/pull/363.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 #363
    
----
commit f7d6953b7dd69698b4a56fe60cf72b666ae2be2b
Author: Chinmay Kulkarni <ch...@...>
Date:   2018-10-12T02:44:47Z

    PHOENIX-4891: An index should inherit UPDATE_CACHE_FREQUENCY setting from parent table
    (WIP Patch)

----


> An index should inherit UPDATE_CACHE_FREQUENCY setting from parent table
> ------------------------------------------------------------------------
>
>                 Key: PHOENIX-4891
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-4891
>             Project: Phoenix
>          Issue Type: Bug
>            Reporter: Lars Hofhansl
>            Assignee: Chinmay Kulkarni
>            Priority: Minor
>
> I tried:
> # creating a table with UPDATE_CACHE_FREQUENCE > 0, then creating a local index on the table.
> # creating a table, then creating the local index, then altering the table setting UPDATE_CACHE_FREQUENCY to > 0
> In both cases the local index did not inherit the setting, verified both by looking at SYSTEM.CATALOG, as well by behavior.
> Update: This also happens for a global index.



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