public class DefaultSolrServerService extends java.lang.Object implements SolrServerService
SolrServerService.| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
EXTENSION_SOLR_SERVER_RESOURCES_PATH |
static java.lang.String |
FAIL_ON_ERROR |
static boolean |
FAIL_ON_ERROR_DEFAULT_VALUE |
static java.lang.String |
INSTANCES_REGEX |
static java.lang.String |
SOLR_INSTANCES_PATH |
| Constructor and Description |
|---|
DefaultSolrServerService() |
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet() |
protected void |
createInstance(SolrInstance solrInstance) |
protected void |
createInstanceConfigDirectory(SolrInstance solrInstance) |
protected void |
createInstanceDataDirectory(SolrInstance solrInstance) |
protected void |
createInstanceLogDirectory(SolrInstance solrInstance) |
SolrInstance |
getInstanceForName(java.lang.String instanceName)
Returns the configured Solr instance for a given name.
|
java.util.Map<java.lang.String,SolrInstance> |
getInstances()
Returns all configured Solr instances.
|
SolrServerControllerFactory |
getSolrServerControllerFactory() |
protected SolrInstance |
initializeInstance(java.lang.String instanceName) |
protected void |
initializeInstances() |
protected boolean |
isFailOnError() |
void |
setSolrServerControllerFactory(SolrServerControllerFactory solrServerControllerFactory) |
void |
startServer(SolrInstance solrInstance)
Starts the Solr server for a given instance.
|
void |
startServers()
Starts all Solr servers that are configured to be automatically started/stopped.
|
void |
stopServer(SolrInstance solrInstance)
Stops the Solr server for a given instance.
|
void |
stopServers()
Stops all Solr servers that are configured to be automatically started/stopped.
|
protected void |
stopServers(java.util.List<SolrInstance> solrInstances) |
public static final java.lang.String SOLR_INSTANCES_PATH
public static final java.lang.String EXTENSION_SOLR_SERVER_RESOURCES_PATH
public static final java.lang.String INSTANCES_REGEX
public static final java.lang.String FAIL_ON_ERROR
public static final boolean FAIL_ON_ERROR_DEFAULT_VALUE
public SolrServerControllerFactory getSolrServerControllerFactory()
public void setSolrServerControllerFactory(SolrServerControllerFactory solrServerControllerFactory)
public java.util.Map<java.lang.String,SolrInstance> getInstances()
SolrServerServicegetInstances in interface SolrServerServicepublic SolrInstance getInstanceForName(java.lang.String instanceName) throws SolrInstanceNotFoundException
SolrServerServicegetInstanceForName in interface SolrServerServiceinstanceName - - the instance nameSolrInstanceNotFoundException - if an instance is not found for the given namepublic void startServer(SolrInstance solrInstance) throws SolrServerException
SolrServerServicestartServer in interface SolrServerServicesolrInstance - - the Solr instanceSolrServerException - if an error occurs while starting the server.public void stopServer(SolrInstance solrInstance) throws SolrServerException
SolrServerServicestopServer in interface SolrServerServicesolrInstance - - the Solr instanceSolrServerException - if an error occurs while stopping the server.public void startServers()
throws SolrServerException
SolrServerServicestartServers in interface SolrServerServiceSolrServerException - if an error occurs while starting the servers, depending on configuration the errors might be ignored
and the exception not thrownSolrInstance.isAutostart()protected void stopServers(java.util.List<SolrInstance> solrInstances) throws SolrServerException
SolrServerExceptionpublic void stopServers()
throws SolrServerException
SolrServerServicestopServers in interface SolrServerServiceSolrServerException - if an error occurs while stopping the servers, depending on configuration the errors might be ignored
and the exception not thrownSolrInstance.isAutostart()public void afterPropertiesSet()
protected void initializeInstances()
protected SolrInstance initializeInstance(java.lang.String instanceName)
protected void createInstance(SolrInstance solrInstance) throws java.io.IOException
java.io.IOExceptionprotected void createInstanceConfigDirectory(SolrInstance solrInstance) throws java.io.IOException
java.io.IOExceptionprotected void createInstanceDataDirectory(SolrInstance solrInstance) throws java.io.IOException
java.io.IOExceptionprotected void createInstanceLogDirectory(SolrInstance solrInstance) throws java.io.IOException
java.io.IOExceptionprotected boolean isFailOnError()
Copyright © 2018 SAP SE. All Rights Reserved.