Repository: phoenix Updated Branches: refs/heads/4.x-HBase-1.0 935be1e30 -> 4fe379bb9
PHOENIX-2926 Skip loading data for table having local indexes when there is split during bulkload job (addendum) Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/4fe379bb Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/4fe379bb Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/4fe379bb Branch: refs/heads/4.x-HBase-1.0 Commit: 4fe379bb96acc1167e78ccb3ea91cf3699b9c369 Parents: 935be1e Author: Ankit Singhal <ankitsingha...@gmail.com> Authored: Wed Jul 6 23:44:04 2016 +0530 Committer: Ankit Singhal <ankitsingha...@gmail.com> Committed: Wed Jul 6 23:44:04 2016 +0530 ---------------------------------------------------------------------- .../org/apache/phoenix/mapreduce/AbstractBulkLoadTool.java | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/phoenix/blob/4fe379bb/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/AbstractBulkLoadTool.java ---------------------------------------------------------------------- diff --git a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/AbstractBulkLoadTool.java b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/AbstractBulkLoadTool.java index faa0a6e..a41de8a 100644 --- a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/AbstractBulkLoadTool.java +++ b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/AbstractBulkLoadTool.java @@ -49,7 +49,6 @@ import org.apache.hadoop.mapreduce.lib.input.FileInputFormat; import org.apache.hadoop.mapreduce.lib.input.TextInputFormat; import org.apache.hadoop.mapreduce.lib.output.FileOutputFormat; import org.apache.hadoop.util.Tool; -import org.apache.phoenix.index.IndexMaintainer; import org.apache.phoenix.jdbc.PhoenixConnection; import org.apache.phoenix.jdbc.PhoenixDatabaseMetaData; import org.apache.phoenix.jdbc.PhoenixDriver; @@ -60,7 +59,6 @@ import org.apache.phoenix.query.QueryConstants; import org.apache.phoenix.schema.PTable; import org.apache.phoenix.schema.PTable.IndexType; import org.apache.phoenix.util.ColumnInfo; -import org.apache.phoenix.util.MetaDataUtil; import org.apache.phoenix.util.PhoenixRuntime; import org.apache.phoenix.util.QueryUtil; import org.apache.phoenix.util.SchemaUtil; @@ -68,7 +66,6 @@ import org.apache.phoenix.util.StringUtil; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import com.google.common.annotations.VisibleForTesting; import com.google.common.base.Preconditions; import com.google.common.base.Splitter; import com.google.common.collect.Lists; @@ -291,7 +288,7 @@ public abstract class AbstractBulkLoadTool extends Configured implements Tool { if(hasLocalIndexes) { try{ table = new HTable(job.getConfiguration(), qualifiedTableName); - splitKeysBeforeJob = table.getRegionLocator().getStartKeys(); + splitKeysBeforeJob = table.getStartKeys(); } finally { if(table != null )table.close(); } @@ -315,7 +312,7 @@ public abstract class AbstractBulkLoadTool extends Configured implements Tool { byte[][] splitKeysAfterJob = null; try { table = new HTable(job.getConfiguration(), qualifiedTableName); - splitKeysAfterJob = table.getRegionLocator().getStartKeys(); + splitKeysAfterJob = table.getStartKeys(); } finally { if (table != null) table.close(); }