lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From m..@apache.org
Subject svn commit: r1163798 - /lucene/dev/branches/branch_3x/solr/core/src/java/org/apache/solr/handler/component/QueryComponent.java
Date Wed, 31 Aug 2011 20:25:08 GMT
Author: mvg
Date: Wed Aug 31 20:25:08 2011
New Revision: 1163798

URL: http://svn.apache.org/viewvc?rev=1163798&view=rev
Log:
Removed unused method

Modified:
    lucene/dev/branches/branch_3x/solr/core/src/java/org/apache/solr/handler/component/QueryComponent.java

Modified: lucene/dev/branches/branch_3x/solr/core/src/java/org/apache/solr/handler/component/QueryComponent.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_3x/solr/core/src/java/org/apache/solr/handler/component/QueryComponent.java?rev=1163798&r1=1163797&r2=1163798&view=diff
==============================================================================
--- lucene/dev/branches/branch_3x/solr/core/src/java/org/apache/solr/handler/component/QueryComponent.java
(original)
+++ lucene/dev/branches/branch_3x/solr/core/src/java/org/apache/solr/handler/component/QueryComponent.java
Wed Aug 31 20:25:08 2011
@@ -388,7 +388,6 @@ public class QueryComponent extends Sear
   public void handleResponses(ResponseBuilder rb, ShardRequest sreq) {
     if ((sreq.purpose & ShardRequest.PURPOSE_GET_TOP_IDS) != 0) {
       mergeIds(rb, sreq);
-      mergeGroupCounts(rb, sreq);
     }
 
     if ((sreq.purpose & ShardRequest.PURPOSE_GET_FIELDS) != 0) {
@@ -661,42 +660,6 @@ public class QueryComponent extends Sear
     }
   }
 
-  /**
-   * Merges the collapse responses from the shards into one distributed collapse response.
-   *
-   * @param rb   The response builder
-   * @param sreq The shard request
-   */
-  private void mergeGroupCounts(ResponseBuilder rb, ShardRequest sreq) {
-    NamedList combinedGroupCounts = new NamedList<Object>();
-
-    for (ShardResponse srsp : sreq.responses) {
-      //check if the namelist is null or not (if a shard crashed)
-      if (srsp.getSolrResponse().getResponse() == null) {
-        continue;
-      }
-
-      NamedList groupCounts = (NamedList<Object>) srsp.getSolrResponse().getResponse().get("groupCount");
-      /*for (Object o : rb.resultIds.keySet()) {
-        String id = (String) o;
-      }*/
-
-      if (groupCounts != null) {
-        for (int i = 0; i < groupCounts.size(); i++) {
-          String groupGroupId = groupCounts.getName(i);
-          ShardDoc sdoc = rb.resultIds.get(groupGroupId);
-          if (sdoc != null) {
-            combinedGroupCounts.add(groupGroupId, groupCounts.getVal(i));
-          }
-        }
-      }
-    }
-
-    if (combinedGroupCounts.size() > 0) {
-      rb.rsp.add("groupCount", combinedGroupCounts);
-    }
-  }
-
   /////////////////////////////////////////////
   ///  SolrInfoMBean
   ////////////////////////////////////////////



Mime
View raw message