Class XmlExportSearchProvider
- java.lang.Object
-
- de.hybris.platform.solrfacetsearch.solr.impl.XmlExportSearchProvider
-
- All Implemented Interfaces:
SolrSearchProvider
public class XmlExportSearchProvider extends java.lang.Object implements SolrSearchProvider
SolrSearchProviderimplementation for XML_EXPORT mode.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface de.hybris.platform.solrfacetsearch.solr.SolrSearchProvider
SolrSearchProvider.CommitType
-
-
Constructor Summary
Constructors Constructor Description XmlExportSearchProvider()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcommit(Index index, SolrSearchProvider.CommitType commitType)Performs a commit on the given index.voidcreateIndex(Index index)Creates an index (if it does not exist).voiddeleteAllDocuments(Index index)Deletes all documents from an index.voiddeleteDocumentsByPk(Index index, java.util.Collection<PK> pks)Deletes documents matching the provided list of pksvoiddeleteIndex(Index index)Deletes an index (if it exists).voiddeleteOldDocuments(Index index, long indexOperationId)Deletes old documents from an index.voidexportConfig(Index index)Exports the configuration to a specific index.org.apache.solr.client.solrj.SolrClientgetClient(Index index)ReturnsSolrClientfor specificIndex, that can be used for searches.org.apache.solr.client.solrj.SolrClientgetClientForIndexing(Index index)ReturnsSolrClientfor specificIndex, that can be used for indexing.IndexNameResolvergetIndexNameResolver()voidoptimize(Index index)Optimizes a given index.IndexresolveIndex(FacetSearchConfig facetSearchConfig, IndexedType indexedType, java.lang.String qualifier)Resolves an index.voidsetIndexNameResolver(IndexNameResolver indexNameResolver)
-
-
-
Method Detail
-
resolveIndex
public Index resolveIndex(FacetSearchConfig facetSearchConfig, IndexedType indexedType, java.lang.String qualifier)
Description copied from interface:SolrSearchProviderResolves an index. Resolving an index only creates a search provider specific instance ofIndex.- Specified by:
resolveIndexin interfaceSolrSearchProvider- Parameters:
facetSearchConfig- - the facet search configurationindexedType- - the indexed typequalifier- - the qualifier- Returns:
- the index
-
getClient
public org.apache.solr.client.solrj.SolrClient getClient(Index index) throws SolrServiceException
Description copied from interface:SolrSearchProviderReturnsSolrClientfor specificIndex, that can be used for searches.- Specified by:
getClientin interfaceSolrSearchProvider- Parameters:
index- - the index- Returns:
SolrClientinstance- Throws:
SolrServiceException- if an error occurs
-
getClientForIndexing
public org.apache.solr.client.solrj.SolrClient getClientForIndexing(Index index) throws SolrServiceException
Description copied from interface:SolrSearchProviderReturnsSolrClientfor specificIndex, that can be used for indexing.- Specified by:
getClientForIndexingin interfaceSolrSearchProvider- Parameters:
index- - the index- Returns:
SolrClientinstance- Throws:
SolrServiceException- if an error occurs
-
createIndex
public void createIndex(Index index) throws SolrServiceException
Description copied from interface:SolrSearchProviderCreates an index (if it does not exist).- Specified by:
createIndexin interfaceSolrSearchProvider- Parameters:
index- - the index- Throws:
SolrServiceException- if an error occurs
-
deleteIndex
public void deleteIndex(Index index) throws SolrServiceException
Description copied from interface:SolrSearchProviderDeletes an index (if it exists).- Specified by:
deleteIndexin interfaceSolrSearchProvider- Parameters:
index- - the index- Throws:
SolrServiceException- if an error occurs
-
exportConfig
public void exportConfig(Index index) throws SolrServiceException
Description copied from interface:SolrSearchProviderExports the configuration to a specific index.- Specified by:
exportConfigin interfaceSolrSearchProvider- Parameters:
index- - the index- Throws:
SolrServiceException- if an error occurs
-
commit
public void commit(Index index, SolrSearchProvider.CommitType commitType) throws SolrServiceException
Description copied from interface:SolrSearchProviderPerforms a commit on the given index. An hard commit makes sure that indexed documents are persisted and visible, a soft commit makes sure indexed documents are visible.- Specified by:
commitin interfaceSolrSearchProvider- Parameters:
index- - the indexcommitType- - the commit type- Throws:
SolrServiceException- if an error occurs
-
optimize
public void optimize(Index index) throws SolrServiceException
Description copied from interface:SolrSearchProviderOptimizes a given index. It does not wait for the operation to complete.- Specified by:
optimizein interfaceSolrSearchProvider- Parameters:
index- - the index- Throws:
SolrServiceException- if an error occurs
-
deleteAllDocuments
public void deleteAllDocuments(Index index) throws SolrServiceException
Description copied from interface:SolrSearchProviderDeletes all documents from an index.- Specified by:
deleteAllDocumentsin interfaceSolrSearchProvider- Parameters:
index- - the index- Throws:
SolrServiceException- if an error occurs
-
deleteOldDocuments
public void deleteOldDocuments(Index index, long indexOperationId) throws SolrServiceException
Description copied from interface:SolrSearchProviderDeletes old documents from an index. Old documents are documents that were not created/updated since a given index operation.- Specified by:
deleteOldDocumentsin interfaceSolrSearchProvider- Parameters:
index- - the indexindexOperationId- - the index operation id- Throws:
SolrServiceException- if an error occurs
-
deleteDocumentsByPk
public void deleteDocumentsByPk(Index index, java.util.Collection<PK> pks)
Description copied from interface:SolrSearchProviderDeletes documents matching the provided list of pks- Specified by:
deleteDocumentsByPkin interfaceSolrSearchProvider- Parameters:
index- - the indexpks- - the pks list
-
getIndexNameResolver
public IndexNameResolver getIndexNameResolver()
-
setIndexNameResolver
public void setIndexNameResolver(IndexNameResolver indexNameResolver)
-
-