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

Samarth Jain commented on PHOENIX-3002:
---------------------------------------

So you are running the offline upgrade before establishing the first connection 
to the cluster (which is what would end up running the 4.8 upgrade code and 
will end up adding  the namespace_enabled column). It should be fine for the 
offline local index upgrade to do the 4.8 upgrade along with upgrading the 
local indexes. 

You can basically do something like this:
{code}
UpgradeUtil.upgradeLocalIndexes(conn, upgradeSystemTables);
{code}
For offline upgrade you will pass upgradeSystemTables as true. For online 
upgrade pass it as false. Then by looking at the value you can accordingly set 
the no_upgrade_attrib. Makes sense?

Also, you don't need the null check here:
{code}
-            if (!Boolean.TRUE.equals(noUpgradeProp)) {
+            if (noUpgradeProp ==null || 
!Boolean.TRUE.equals(Boolean.valueOf(noUpgradeProp))) {
{code}

> Upgrading to 4.8 doesn't recreate local indexes
> -----------------------------------------------
>
>                 Key: PHOENIX-3002
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-3002
>             Project: Phoenix
>          Issue Type: Bug
>            Reporter: Samarth Jain
>            Assignee: Rajeshbabu Chintaguntla
>            Priority: Blocker
>             Fix For: 4.8.0
>
>         Attachments: PHOENIX-3002.patch, PHOENIX-3002_v0.patch, 
> PHOENIX-3002_v1.patch, PHOENIX-3002_v2.patch
>
>
> [~rajeshbabu] - I noticed that when upgrading to 4.8, local indexes created 
> with 4.7 or before aren't getting recreated with the new local indexes 
> implementation.  I am not seeing the metadata rows for the recreated indices 
> in SYSTEM.CATALOG.



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

Reply via email to