gjacoby126 commented on a change in pull request #666: Phoenix-5652 Improve 
IndexScrutinyTool perf by using SkipScan in index table queries
URL: https://github.com/apache/phoenix/pull/666#discussion_r365369370
 
 

 ##########
 File path: 
phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexScrutinyTool.java
 ##########
 @@ -259,18 +266,20 @@ public Job createSubmittableJob(String schemaName, 
String indexTable, String dat
 
             // set CURRENT_SCN for our scan so that incoming writes don't 
throw off scrutiny
             configuration.set(PhoenixConfigurationUtil.CURRENT_SCN_VALUE, 
Long.toString(ts));
+            String tenantId = 
configuration.get(PhoenixRuntime.TENANT_ID_ATTRIB);
 
             // set the source table to either data or index table
             SourceTargetColumnNames columnNames =
                     SourceTable.DATA_TABLE_SOURCE.equals(sourceTable)
                             ? new 
SourceTargetColumnNames.DataSourceColNames(pdataTable,
-                                    pindexTable)
+                                    pindexTable, tenantId)
                             : new 
SourceTargetColumnNames.IndexSourceColNames(pdataTable,
-                                    pindexTable);
+                                    pindexTable, tenantId);
             String qSourceTable = columnNames.getQualifiedSourceTableName();
-            List<String> sourceColumnNames = columnNames.getSourceColNames();
-            List<String> sourceDynamicCols = 
columnNames.getSourceDynamicCols();
-            List<String> targetDynamicCols = 
columnNames.getTargetDynamicCols();
+
+            List<String> sourceColumnNames = 
columnNames.getSourceColNamesForSkipScan();
 
 Review comment:
   Seems like we're "leaking" implementation details here...is there a reason 
why the job creator function needs to know the Scan's going to be a skip scan? 
Why should it need to change in the future if we decide to use a different Scan 
filter?

----------------------------------------------------------------
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