You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@phoenix.apache.org by ra...@apache.org on 2020/03/13 12:23:19 UTC

[phoenix] branch 4.x updated: PHOENIX-5731 Loading bulkload hfiles should not be blocked if the upsert select happening for differet table.(Rajeshbabu)-addendum

This is an automated email from the ASF dual-hosted git repository.

rajeshbabu pushed a commit to branch 4.x
in repository https://gitbox.apache.org/repos/asf/phoenix.git


The following commit(s) were added to refs/heads/4.x by this push:
     new 24be0d5  PHOENIX-5731 Loading bulkload hfiles should not be blocked if the upsert select happening for differet table.(Rajeshbabu)-addendum
24be0d5 is described below

commit 24be0d5239b81dd95ae076bb6909be7fe0143c27
Author: Rajeshbabu Chintaguntla <ra...@apache.org>
AuthorDate: Fri Mar 13 17:53:08 2020 +0530

    PHOENIX-5731 Loading bulkload hfiles should not be blocked if the upsert select happening for differet table.(Rajeshbabu)-addendum
---
 .../phoenix/coprocessor/UngroupedAggregateRegionObserver.java     | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/UngroupedAggregateRegionObserver.java b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/UngroupedAggregateRegionObserver.java
index 4f21511..0547a62 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/UngroupedAggregateRegionObserver.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/UngroupedAggregateRegionObserver.java
@@ -528,11 +528,13 @@ public class UngroupedAggregateRegionObserver extends BaseScannerRegionObserver
         if(buildLocalIndex) {
             checkForLocalIndexColumnFamilies(region, indexMaintainers);
         }
-        if (isDescRowKeyOrderUpgrade || isDelete ||
-                (isUpsert && (targetHTable == null ||
-                        targetHTable.getName().equals(region.getTableDesc().getTableName())))
+        if (isDescRowKeyOrderUpgrade || isDelete || isUpsert
                 || (deleteCQ != null && deleteCF != null) || emptyCF != null || buildLocalIndex) {
             needToWrite = true;
+            if((isUpsert && (targetHTable == null ||
+                    !targetHTable.getName().equals(region.getTableDesc().getTableName())))) {
+                needToWrite = false;
+            }
             maxBatchSize = conf.getInt(MUTATE_BATCH_SIZE_ATTRIB, QueryServicesOptions.DEFAULT_MUTATE_BATCH_SIZE);
             mutations = new MutationList(Ints.saturatedCast(maxBatchSize + maxBatchSize / 10));
             maxBatchSizeBytes = conf.getLong(MUTATE_BATCH_SIZE_BYTES_ATTRIB,