lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From markrmil...@apache.org
Subject svn commit: r1294862 - /lucene/dev/trunk/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandler.java
Date Tue, 28 Feb 2012 22:25:30 GMT
Author: markrmiller
Date: Tue Feb 28 22:25:29 2012
New Revision: 1294862

URL: http://svn.apache.org/viewvc?rev=1294862&view=rev
Log:
use qt param

Modified:
    lucene/dev/trunk/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandler.java

Modified: lucene/dev/trunk/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandler.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandler.java?rev=1294862&r1=1294861&r2=1294862&view=diff
==============================================================================
--- lucene/dev/trunk/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandler.java
(original)
+++ lucene/dev/trunk/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandler.java
Tue Feb 28 22:25:29 2012
@@ -777,8 +777,9 @@ public class CoreAdminHandler extends Re
         final ZkNodeProps node = shardEntry.getValue();
         if (cloudState.liveNodesContain(node.get(ZkStateReader.NODE_NAME_PROP))) {
           newParams.set(CoreAdminParams.CORE, node.get(ZkStateReader.CORE_NAME_PROP));
-          String replica = node.get(ZkStateReader.BASE_URL_PROP) + "/admin/cores";
+          String replica = node.get(ZkStateReader.BASE_URL_PROP);
           ShardRequest sreq = new ShardRequest();
+          newParams.set("qt", "/admin/cores");
           sreq.purpose = 1;
           // TODO: this sucks
           if (replica.startsWith("http://"))
@@ -795,9 +796,11 @@ public class CoreAdminHandler extends Re
     ShardResponse srsp;
     do {
       srsp = shardHandler.takeCompletedOrError();
-      Throwable e = srsp.getException();
-      if (e != null) {
-        log.error("Error talking to shard: " + srsp.getShard(), e);
+      if (srsp != null) {
+        Throwable e = srsp.getException();
+        if (e != null) {
+          log.error("Error talking to shard: " + srsp.getShard(), e);
+        }
       }
     } while(srsp != null);
     



Mime
View raw message