[
https://issues.apache.org/jira/browse/PHOENIX-6587?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17519387#comment-17519387
]
ASF GitHub Bot commented on PHOENIX-6587:
-----------------------------------------
stoty commented on code in PR #1353:
URL: https://github.com/apache/phoenix/pull/1353#discussion_r845840844
##########
phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionlessQueryServicesImpl.java:
##########
@@ -289,8 +289,11 @@ public MetaDataMutationResult getTable(PName tenantId,
byte[] schemaBytes, byte[
}
private static List<HRegionLocation> generateRegionLocations(byte[]
physicalName, byte[][] splits) {
- byte[] startKey = HConstants.EMPTY_START_ROW;
List<HRegionLocation> regions =
Lists.newArrayListWithExpectedSize(splits.length);
+ if (splits.length == 0) {
+ return regions;
+ }
+ byte[] startKey = HConstants.EMPTY_START_ROW;
Review Comment:
This won't compile, we need an empty List to return.
> Handle explicit pre-splits for new salted tables and validate splits when
> creating salted tables on existing HBase tables
> -------------------------------------------------------------------------------------------------------------------------
>
> Key: PHOENIX-6587
> URL: https://issues.apache.org/jira/browse/PHOENIX-6587
> Project: Phoenix
> Issue Type: Bug
> Components: core
> Affects Versions: 5.2.0
> Reporter: Istvan Toth
> Assignee: Istvan Toth
> Priority: Minor
>
> Specifying the split points manually on salted tables can break them.
> The easiest thing to do is to disallow it, which ensures that the table is
> created with the default per bucket presplit.
--
This message was sent by Atlassian Jira
(v8.20.1#820001)