[
https://issues.apache.org/jira/browse/PHOENIX-1147?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14088472#comment-14088472
]
James Taylor commented on PHOENIX-1147:
---------------------------------------
The change to FromCompiler shouldn't be necessary, as we call updateCache
before we commit. Can you try without that?
{code}
--- phoenix-core/src/main/java/org/apache/phoenix/compile/FromCompiler.java
+++ phoenix-core/src/main/java/org/apache/phoenix/compile/FromCompiler.java
@@ -275,7 +275,8 @@ public class FromCompiler {
String fullTableName = SchemaUtil.getTableName(schemaName,
tableName);
PName tenantId = connection.getTenantId();
PTable theTable = null;
- if (updateCacheImmediately || connection.getAutoCommit()) {
+ if (updateCacheImmediately || connection.getAutoCommit() ||
+ (connection.getMutationState().getPendingUpdateCount() ==
0)) {
MetaDataMutationResult result = client.updateCache(schemaName,
tableName);
timeStamp = result.getMutationTime();
theTable = result.getTable();
{code}
> Add test cases to cover more index update failure scenarios
> -----------------------------------------------------------
>
> Key: PHOENIX-1147
> URL: https://issues.apache.org/jira/browse/PHOENIX-1147
> Project: Phoenix
> Issue Type: Bug
> Affects Versions: 4.0.0, 5.0.0
> Reporter: Jeffrey Zhong
> Assignee: Jeffrey Zhong
> Attachments: Phoenix-1147-v1.patch
>
>
> Add one test to cover RegionServer being killed while index is begin updated
> Add steps to make sure UPSERT & SELECT should still work after index is
> disabled.
--
This message was sent by Atlassian JIRA
(v6.2#6252)