这个问题是当collection中数据过大时,把 SolrQuery .setRows(Integer.MAX_VALUE) 查询行设为最大值引起的。把行数设为合理值后可以解决该问题。
org.apache.solr.client.solrj.SolrServerException: No live SolrServers available to handle this request:[http://10.23.71.10:8983/solr/collection, http://10.23.71.11:8983/solr/collection, http://10.23.71.12:8983/solr/collection]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_161]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_161]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_161]
at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_161]
at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:189) [spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE]