You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by ma...@apache.org on 2011/12/14 18:42:33 UTC

svn commit: r1214377 - /lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/processor/DistributedUpdateProcessor.java

Author: markrmiller
Date: Wed Dec 14 17:42:33 2011
New Revision: 1214377

URL: http://svn.apache.org/viewvc?rev=1214377&view=rev
Log:
we need to check for existence of cloud descriptor

Modified:
    lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/processor/DistributedUpdateProcessor.java

Modified: lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/processor/DistributedUpdateProcessor.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/processor/DistributedUpdateProcessor.java?rev=1214377&r1=1214376&r2=1214377&view=diff
==============================================================================
--- lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/processor/DistributedUpdateProcessor.java (original)
+++ lucene/dev/branches/solrcloud/solr/core/src/java/org/apache/solr/update/processor/DistributedUpdateProcessor.java Wed Dec 14 17:42:33 2011
@@ -27,6 +27,7 @@ import java.util.Set;
 
 import org.apache.lucene.util.BytesRef;
 import org.apache.lucene.util.CharsRef;
+import org.apache.solr.cloud.CloudDescriptor;
 import org.apache.solr.cloud.HashPartitioner;
 import org.apache.solr.cloud.HashPartitioner.Range;
 import org.apache.solr.cloud.ZkController;
@@ -123,7 +124,11 @@ public class DistributedUpdateProcessor 
     
     zkController = req.getCore().getCoreDescriptor().getCoreContainer().getZkController();
     
-    collection = coreDesc.getCloudDescriptor().getCollectionName();
+    CloudDescriptor cloudDesc = coreDesc.getCloudDescriptor();
+    
+    if (cloudDesc != null) {
+      collection = cloudDesc.getCollectionName();
+    }
     
     cmdDistrib = new SolrCmdDistributor(rsp); // TODO: we put the last result (which could be complicated due to 
                                               // multiple docs per req) in the rsp - this is whack