public class SolrClientUtils extends Object
SolrClientUtils
replaces SolrServerUtils from version 1.xModifier and Type | Method and Description |
---|---|
static String |
appendCoreToBaseUrl(String baseUrl,
String core)
Append core to given baseUrl
|
static <T extends org.apache.solr.client.solrj.SolrClient> |
clone(T solrClient) |
static <T extends org.apache.solr.client.solrj.SolrClient> |
clone(T solrClient,
String core)
Create a clone of given
SolrClient and modify baseUrl of clone to point to the given core. |
static String |
resolveSolrCoreName(Class<?> type)
Resolve solr core/collection name for given type.
|
public static String resolveSolrCoreName(Class<?> type)
type
- SolrDocument
not present or SolrDocument.solrCoreName()
is blank.public static <T extends org.apache.solr.client.solrj.SolrClient> T clone(T solrClient)
public static <T extends org.apache.solr.client.solrj.SolrClient> T clone(T solrClient, String core)
SolrClient
and modify baseUrl of clone to point to the given core.solrClient
- Non null reference SolrClient
to copy properties from.core
- Name of solr core to point to.BeanInstantiationException
- if creating instance failedCopyright © 2011-2015–2017 Pivotal Software, Inc.. All rights reserved.