Class HttpSolrClientFactoryBean
java.lang.Object
org.springframework.data.solr.server.support.HttpSolrClientFactory
org.springframework.data.solr.server.support.HttpSolrClientFactoryBean
- All Implemented Interfaces:
org.springframework.beans.factory.DisposableBean,org.springframework.beans.factory.FactoryBean<org.apache.solr.client.solrj.SolrClient>,org.springframework.beans.factory.InitializingBean,SolrClientFactory
public class HttpSolrClientFactoryBean
extends HttpSolrClientFactory
implements org.springframework.beans.factory.FactoryBean<org.apache.solr.client.solrj.SolrClient>, org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.DisposableBean
HttpSolrClientFactoryBean replaces HttpSolrServerFactoryBean from version 1.x.- Since:
- 2.0
-
Field Summary
Fields inherited from interface org.springframework.beans.factory.FactoryBean
OBJECT_TYPE_ATTRIBUTE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoiddestroy()protected voiddestroy(org.apache.solr.client.solrj.SolrClient client) org.apache.solr.client.solrj.SolrClientClass<?>org.apache.solr.client.solrj.SolrClientGet baseSolrClientinstanceprotected final booleanisHttpSolrClient(org.apache.solr.client.solrj.SolrClient solrClient) booleanvoidsetMaxConnections(Integer maxConnections) voidsetSolrClient(org.apache.solr.client.solrj.SolrClient solrClient) voidsetTimeout(Integer timeout) voidMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.springframework.beans.factory.DisposableBean
destroy
-
Constructor Details
-
HttpSolrClientFactoryBean
public HttpSolrClientFactoryBean()
-
-
Method Details
-
afterPropertiesSet
- Specified by:
afterPropertiesSetin interfaceorg.springframework.beans.factory.InitializingBean- Throws:
Exception
-
getObject
- Specified by:
getObjectin interfaceorg.springframework.beans.factory.FactoryBean<org.apache.solr.client.solrj.SolrClient>- Throws:
Exception
-
getObjectType
- Specified by:
getObjectTypein interfaceorg.springframework.beans.factory.FactoryBean<org.apache.solr.client.solrj.SolrClient>
-
isSingleton
public boolean isSingleton()- Specified by:
isSingletonin interfaceorg.springframework.beans.factory.FactoryBean<org.apache.solr.client.solrj.SolrClient>
-
setUrl
-
setTimeout
-
setMaxConnections
-
isHttpSolrClient
protected final boolean isHttpSolrClient(org.apache.solr.client.solrj.SolrClient solrClient) -
getSolrClient
public org.apache.solr.client.solrj.SolrClient getSolrClient()Description copied from interface:SolrClientFactoryGet baseSolrClientinstance- Specified by:
getSolrClientin interfaceSolrClientFactory- Returns:
- a reusable SolrClient instance
-
setSolrClient
public void setSolrClient(org.apache.solr.client.solrj.SolrClient solrClient) -
destroy
public void destroy()- Specified by:
destroyin interfaceorg.springframework.beans.factory.DisposableBean
-
destroy
protected void destroy(org.apache.solr.client.solrj.SolrClient client) - Parameters:
client-
-