You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by sa...@apache.org on 2014/03/25 05:04:41 UTC
svn commit: r1581219 - in /lucene/dev/branches/lucene_solr_4_7: ./ solr/
solr/CHANGES.txt solr/solrj/
solr/solrj/src/java/org/apache/solr/client/solrj/impl/CloudSolrServer.java
Author: sarowe
Date: Tue Mar 25 04:04:41 2014
New Revision: 1581219
URL: http://svn.apache.org/r1581219
Log:
SOLR-5874: Unsafe cast in CloudSolrServer's RouteException. Change RouteException to handle Throwable rather than Exception.
SOLR-5899: CloudSolrServer's RouteResponse and RouteException should be publicly accessible.
(merged branch_4x r1580553)
Modified:
lucene/dev/branches/lucene_solr_4_7/ (props changed)
lucene/dev/branches/lucene_solr_4_7/solr/ (props changed)
lucene/dev/branches/lucene_solr_4_7/solr/CHANGES.txt (contents, props changed)
lucene/dev/branches/lucene_solr_4_7/solr/solrj/ (props changed)
lucene/dev/branches/lucene_solr_4_7/solr/solrj/src/java/org/apache/solr/client/solrj/impl/CloudSolrServer.java
Modified: lucene/dev/branches/lucene_solr_4_7/solr/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene_solr_4_7/solr/CHANGES.txt?rev=1581219&r1=1581218&r2=1581219&view=diff
==============================================================================
--- lucene/dev/branches/lucene_solr_4_7/solr/CHANGES.txt (original)
+++ lucene/dev/branches/lucene_solr_4_7/solr/CHANGES.txt Tue Mar 25 04:04:41 2014
@@ -108,6 +108,13 @@ Bug Fixes
* SOLR-5839: ZookeeperInfoServlet does not trim path properly.
(Furkan KAMACI via Mark Miller)
+* SOLR-5874: Unsafe cast in CloudSolrServer's RouteException. Change
+ RouteException to handle Throwable rather than Exception.
+ (Mark Miller, David Arthur)
+
+* SOLR-5899: CloudSolrServer's RouteResponse and RouteException should be
+ publicly accessible. (Mark Miller, shalin)
+
Other Changes
---------------------
Modified: lucene/dev/branches/lucene_solr_4_7/solr/solrj/src/java/org/apache/solr/client/solrj/impl/CloudSolrServer.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene_solr_4_7/solr/solrj/src/java/org/apache/solr/client/solrj/impl/CloudSolrServer.java?rev=1581219&r1=1581218&r2=1581219&view=diff
==============================================================================
--- lucene/dev/branches/lucene_solr_4_7/solr/solrj/src/java/org/apache/solr/client/solrj/impl/CloudSolrServer.java (original)
+++ lucene/dev/branches/lucene_solr_4_7/solr/solrj/src/java/org/apache/solr/client/solrj/impl/CloudSolrServer.java Tue Mar 25 04:04:41 2014
@@ -311,8 +311,8 @@ public class CloudSolrServer extends Sol
return null;
}
- NamedList exceptions = new NamedList();
- NamedList shardResponses = new NamedList();
+ NamedList<Throwable> exceptions = new NamedList<Throwable>();
+ NamedList<NamedList> shardResponses = new NamedList<NamedList>();
Map<String, LBHttpSolrServer.Req> routes = updateRequest.getRoutes(router, col, urlMap, routableParams, this.idField);
if (routes == null) {
@@ -453,7 +453,7 @@ public class CloudSolrServer extends Sol
return condensed;
}
- class RouteResponse extends NamedList {
+ public static class RouteResponse extends NamedList {
private NamedList routeResponses;
private Map<String, LBHttpSolrServer.Req> routes;
@@ -475,19 +475,19 @@ public class CloudSolrServer extends Sol
}
- class RouteException extends SolrException {
+ public static class RouteException extends SolrException {
- private NamedList exceptions;
+ private NamedList<Throwable> throwables;
private Map<String, LBHttpSolrServer.Req> routes;
- public RouteException(ErrorCode errorCode, NamedList exceptions, Map<String, LBHttpSolrServer.Req> routes){
- super(errorCode, ((Exception)exceptions.getVal(0)).getMessage(), (Exception)exceptions.getVal(0));
- this.exceptions = exceptions;
+ public RouteException(ErrorCode errorCode, NamedList<Throwable> throwables, Map<String, LBHttpSolrServer.Req> routes){
+ super(errorCode, throwables.getVal(0).getMessage(), throwables.getVal(0));
+ this.throwables = throwables;
this.routes = routes;
}
- public NamedList getExceptions() {
- return exceptions;
+ public NamedList<Throwable> getThrowables() {
+ return throwables;
}
public Map<String, LBHttpSolrServer.Req> getRoutes() {