priyankporwal commented on a change in pull request #596: PHOENIX-5512 
Indextool should set disabled index to active
URL: https://github.com/apache/phoenix/pull/596#discussion_r372172768
 
 

 ##########
 File path: 
phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
 ##########
 @@ -785,6 +784,12 @@ public int run(String[] args) throws Exception {
                                fs.delete(outputPath, true);
                        }
 
+            // We have to mark Disable index to Building before we can set it 
to Active in the reducer. Otherwise it errors out with
+            // index state transition error
+                       if (pIndexTable != null && pIndexTable.getIndexState() 
== PIndexState.DISABLE) {
+                
IndexUtil.updateIndexState(connection.unwrap(PhoenixConnection.class),
 
 Review comment:
   Are there any implications of INDEX_DISABLE_TIMESTAMP being 0 or non-0?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to