Class SolrFacetConfig
java.lang.Object
org.springframework.extensions.surf.util.AbstractLifecycleBean
org.alfresco.repo.search.impl.solr.facet.SolrFacetConfig
- All Implemented Interfaces:
EventListener,org.springframework.beans.factory.Aware,org.springframework.context.ApplicationContextAware,org.springframework.context.ApplicationListener
public class SolrFacetConfig
extends org.springframework.extensions.surf.util.AbstractLifecycleBean
This class picks up all the loaded properties passed to it and uses a naming
convention to isolate the default and custom facets and related values.
So, if a new facet filter_abc is required for the
cm:content.mimetype, then the following needs to be put into a
properties file. The search for the additional custom properties file is
tomcat/shared/classes/alfresco/extension/solr-facets-config-custom.properties:
${solr_facets.inheritanceHierarchy}
The default inheritance orders are:
solr_facets.inheritanceHierarchy=default,custom i.e. the default facet's values are retrieved first and then overlayed with values from the custom facet.
- custom.cm\:content.mimetype.filterID=filter_abc
- custom.cm\:content.mimetype.displayName=faceted-search.facet-menu.facet.formats
- custom.cm\:content.mimetype.displayControl=alfresco/search/FacetFilters
- custom.cm\:content.mimetype.maxFilters=5
- custom.cm\:content.mimetype.hitThreshold=1
- custom.cm\:content.mimetype.minFilterValueLength=4
- custom.cm\:content.mimetype.sortBy=DESCENDING
- custom.cm\:content.mimetype.scope=SCOPED_SITES
- custom.cm\:content.mimetype.scopedSites=site1,site2,site3
- custom.cm\:content.mimetype.isEnabled=true
- custom.cm\:content.mimetype.EXTRA-PROP.blockIncludeFacetRequest=true
- custom.cm\:content.mimetype.EXTRA-PROP.moreProp=additionalInfo
${solr_facets.inheritanceHierarchy}
The default inheritance orders are:
solr_facets.inheritanceHierarchy=default,custom i.e. the default facet's values are retrieved first and then overlayed with values from the custom facet.
- Author:
- Jamal Kaabi-Mofrad
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic enum -
Field Summary
Fields inherited from class org.springframework.extensions.surf.util.AbstractLifecycleBean
log -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidonBootstrap(org.springframework.context.ApplicationEvent event) protected voidonShutdown(org.springframework.context.ApplicationEvent event) voidsetNamespaceService(NamespaceService namespaceService) Methods inherited from class org.springframework.extensions.surf.util.AbstractLifecycleBean
getApplicationContext, onApplicationEvent, setApplicationContextMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.springframework.context.ApplicationListener
supportsAsyncExecution
-
Constructor Details
-
SolrFacetConfig
-
-
Method Details
-
setNamespaceService
- Parameters:
namespaceService- the namespaceService to set
-
getDefaultFacets
-
onBootstrap
protected void onBootstrap(org.springframework.context.ApplicationEvent event) - Specified by:
onBootstrapin classorg.springframework.extensions.surf.util.AbstractLifecycleBean
-
onShutdown
protected void onShutdown(org.springframework.context.ApplicationEvent event) - Specified by:
onShutdownin classorg.springframework.extensions.surf.util.AbstractLifecycleBean
-