You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@phoenix.apache.org by "James Taylor (JIRA)" <ji...@apache.org> on 2016/06/06 17:49:21 UTC
[jira] [Commented] (PHOENIX-2966) Implement mechanism to build
async indexes when running locally
[ https://issues.apache.org/jira/browse/PHOENIX-2966?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15316863#comment-15316863 ]
James Taylor commented on PHOENIX-2966:
---------------------------------------
The simplest way to do this is to mimic what is done in PHOENIX-2950. There are three parts to this:
- Determine when we're running locally. The simplest way is to check the {{hbase.cluster.distributed}} config parameter. If false, we know we need to use this new mechanism to start async index builds in a different way. We need to make this check on the *server-side* as the client-side config will not have this property.
- Start a scheduled thread which queries the SYSTEM.CATALOG table in the same way as is done in PHOENIX-2950 to determine which indexes need to be built.
- Issue a {{ALTER INDEX <index name> ON <table name> REBUILD}} call on each index that needs to be built.
The best place for this code to live would be MetaDataRegionObserver which is a coprocessor that is only installed on the {{SYSTEM.CATALOG}} table. The existing code in that class is already starting a scheduled task - perhaps this functionality can be folded into the same runnable?
> Implement mechanism to build async indexes when running locally
> ---------------------------------------------------------------
>
> Key: PHOENIX-2966
> URL: https://issues.apache.org/jira/browse/PHOENIX-2966
> Project: Phoenix
> Issue Type: Sub-task
> Reporter: James Taylor
> Fix For: 4.8.0
>
>
> For local, non distributed environments, we need to build indexes that were build asynchronously.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)