incubator-blur-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From amccu...@apache.org
Subject git commit: Fixing issue when using using bulk ingestion and there are read only tables present.
Date Fri, 10 Apr 2015 00:50:17 GMT
Repository: incubator-blur
Updated Branches:
  refs/heads/master 5657f1b09 -> 049e5728f


Fixing issue when using using bulk ingestion and there are read only tables present.


Project: http://git-wip-us.apache.org/repos/asf/incubator-blur/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-blur/commit/049e5728
Tree: http://git-wip-us.apache.org/repos/asf/incubator-blur/tree/049e5728
Diff: http://git-wip-us.apache.org/repos/asf/incubator-blur/diff/049e5728

Branch: refs/heads/master
Commit: 049e5728f8d67dbecc680e8cbd7962443aeadbe0
Parents: 5657f1b
Author: Aaron McCurry <amccurry@gmail.com>
Authored: Thu Apr 9 20:45:24 2015 -0400
Committer: Aaron McCurry <amccurry@gmail.com>
Committed: Thu Apr 9 20:45:24 2015 -0400

----------------------------------------------------------------------
 .../main/java/org/apache/blur/thrift/BlurShardServer.java    | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/049e5728/blur-core/src/main/java/org/apache/blur/thrift/BlurShardServer.java
----------------------------------------------------------------------
diff --git a/blur-core/src/main/java/org/apache/blur/thrift/BlurShardServer.java b/blur-core/src/main/java/org/apache/blur/thrift/BlurShardServer.java
index b993eb6..d0772b4 100644
--- a/blur-core/src/main/java/org/apache/blur/thrift/BlurShardServer.java
+++ b/blur-core/src/main/java/org/apache/blur/thrift/BlurShardServer.java
@@ -720,7 +720,13 @@ public class BlurShardServer extends TableAdmin implements Iface {
       TException {
     try {
       List<String> tableListByCluster = tableListByCluster(_cluster);
-      _indexManager.bulkMutateFinish(new HashSet<String>(tableListByCluster), bulkId,
apply, blockUntilComplete);
+      List<String> writableTables = new ArrayList<String>();
+      for (String table :tableListByCluster) {
+        if (_clusterStatus.isReadOnly(true, _cluster, table)) {
+          writableTables.add(table);
+        }
+      }
+      _indexManager.bulkMutateFinish(new HashSet<String>(writableTables), bulkId, apply,
blockUntilComplete);
     } catch (Exception e) {
       LOG.error("Unknown error while trying to finsh a bulk mutate [" + bulkId + "]", e);
       if (e instanceof BlurException) {


Mime
View raw message