<?xml version="1.0" encoding="UTF-8"?>

<!--
    The contents of this file are subject to the license and copyright
    detailed in the LICENSE and NOTICE files at the root of the source
    tree and available online at
    http://www.dspace.org/license/
-->

<beans xmlns="http://www.springframework.org/schema/beans"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xmlns:context="http://www.springframework.org/schema/context"
       xmlns:util="http://www.springframework.org/schema/util"
       xsi:schemaLocation="http://www.springframework.org/schema/beans
           http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
           http://www.springframework.org/schema/context
           http://www.springframework.org/schema/context/spring-context-3.0.xsd
           http://www.springframework.org/schema/util
           http://www.springframework.org/schema/util/spring-util-3.0.xsd"
       default-autowire-candidates="*Service,*DAO,javax.sql.DataSource,*Plugin" default-lazy-init="true">

    <context:annotation-config /> <!-- allows us to use spring annotations in beans -->

    <!--Bean that is used for mapping communities/collections to certain discovery configurations.-->
    <bean id="org.dspace.discovery.configuration.DiscoveryConfigurationService" class="org.dspace.discovery.configuration.DiscoveryConfigurationService">
        <property name="map">
            <map>
                <!--The map containing all the settings,
                    the key is used to refer to the page (the "site" or a community/collection handle)
                    the value-ref is a reference to an identifier of the DiscoveryConfiguration format
                    -->
                <!-- The default entry, DO NOT REMOVE the system requires this -->
                <entry key="default" value-ref="defaultConfiguration" />
                <!-- Same as the "default" configuration, but does NOT filter out older versions of items -->
                <!-- Used to display related items on single-item pages, because a relationship does not always point to the latest version of the related item -->
                <entry key="default-relationships" value-ref="defaultRelationshipsConfiguration" />
                <!--<entry key="123456789/7621" value-ref="defaultConfiguration"/>-->
                <!-- Used to show filters and results on MyDSpace -->
                <!-- Do not change the id of special entries or else they won't work -->
                <!-- "workspace" is a special entry to search for your own workspace items -->
                <entry key="workspace" value-ref="workspaceConfiguration" />
                <entry key="supervisedWorkspace" value-ref="supervisedWorkspaceConfiguration" />
                <!-- "workflow" is a special entry to search for your own workflow tasks -->
                <entry key="workflow" value-ref="workflowConfiguration" />
                <!-- "workflowAdmin" is a special entry to search for all workflow items if you are an administrator -->
                <entry key="workflowAdmin" value-ref="workflowAdminConfiguration" />
                <!-- "supervision" is a special entry to search for all workspace and workflow items if you are an administrator -->
                <entry key="supervision" value-ref="supervisionConfiguration" />
                <entry key="undiscoverable" value-ref="unDiscoverableItems" />
                <entry key="administrativeView" value-ref="administrativeView" />

                <entry key="publication" value-ref="publication"/>
                <!-- Same as the "publication" configuration, but does NOT filter out older versions of items -->
                <!-- Used to display related items on single-item pages, because a relationship does not always point to the latest version of the related item -->
                <entry key="publication-relationships" value-ref="publicationRelationships"/>

                <entry key="person" value-ref="person"/>
                <!-- Same as the "person" configuration, but does NOT filter out older versions of items -->
                <!-- Used to display related items on single-item pages, because a relationship does not always point to the latest version of the related item -->
                <entry key="person-relationships" value-ref="personRelationships"/>

                <entry key="orgunit" value-ref="orgUnit"/>
                <!-- Same as the "orgunit" configuration, but does NOT filter out older versions of items -->
                <!-- Used to display related items on single-item pages, because a relationship does not always point to the latest version of the related item -->
                <entry key="orgunit-relationships" value-ref="orgUnitRelationships"/>

                <entry key="journalissue" value-ref="journalIssue"/>
                <!-- Same as the "journalissue" configuration, but does NOT filter out older versions of items -->
                <!-- Used to display related items on single-item pages, because a relationship does not always point to the latest version of the related item -->
                <entry key="journalissue-relationships" value-ref="journalIssueRelationships"/>

                <entry key="journalvolume" value-ref="journalVolume"/>
                <!-- Same as the "journalvolume" configuration, but does NOT filter out older versions of items -->
                <!-- Used to display related items on single-item pages, because a relationship does not always point to the latest version of the related item -->
                <entry key="journalvolume-relationships" value-ref="journalVolumeRelationships"/>

                <entry key="journal" value-ref="journal"/>
                <!-- Same as the "journal" configuration, but does NOT filter out older versions of items -->
                <!-- Used to display related items on single-item pages, because a relationship does not always point to the latest version of the related item -->
                <entry key="journal-relationships" value-ref="journalRelationships"/>

                <entry key="project" value-ref="project"/>
                <!-- Same as the "project" configuration, but does NOT filter out older versions of items -->
                <!-- Used to display related items on single-item pages, because a relationship does not always point to the latest version of the related item -->
                <entry key="project-relationships" value-ref="projectRelationships"/>

                <!-- search for an entity that can be a Person or an OrgUnit -->
                <entry key="personOrOrgunit" value-ref="personOrOrgunit"/>
                <!-- Openaire4 guidelines - search for an OrgUnit that have a specific dc.type=FundingOrganization -->
                <entry key="openaireFundingAgency" value-ref="openaireFundingAgency"/>
                <entry key="eperson_claims" value-ref="eperson_claims"/>
                <!-- COAR NOTIFY LDN MESSAGES configuration -->
                <entry key="NOTIFY.incoming" value-ref="NOTIFY.incoming"/>
                <entry key="NOTIFY.outgoing" value-ref="NOTIFY.outgoing"/>

                <!-- Configuration for scope based tests -->
                <!-- See org.dspace.app.rest.DiscoveryScopeBasedRestControllerIT for more information -->
                <entry key="123456789/discovery-parent-community-1" value-ref="discovery-parent-community-1"/>
                <entry key="123456789/discovery-sub-community-1-1" value-ref="discovery-sub-community-1-1"/>
                <entry key="123456789/discovery-collection-1-1-1" value-ref="discovery-collection-1-1-1"/>
                <entry key="123456789/discovery-collection-1-2-1" value-ref="discovery-collection-1-2-1"/>
                <entry key="123456789/discovery-sub-community-2-1" value-ref="discovery-sub-community-2-1"/>
                <entry key="123456789/discovery-collection-2-1-1" value-ref="discovery-collection-2-1-1"/>
                <entry key="123456789/discovery-collection-2-2-1" value-ref="discovery-collection-2-2-1"/>
            </map>
        </property>
        <property name="toIgnoreMetadataFields">
            <map>
                <entry>
                    <key><util:constant static-field="org.dspace.core.Constants.COMMUNITY"/></key>
                    <list>
                        <!--Introduction text-->
                        <!--<value>dc.description</value>-->
                        <!--Short description-->
                        <!--<value>dc.description.abstract</value>-->
                        <!--News-->
                        <!--<value>dc.description.tableofcontents</value>-->
                        <!--Copyright text-->
                        <value>dc.rights</value>
                        <!--Community name-->
                        <!--<value>dc.title</value>-->
                    </list>
                </entry>
                <entry>
                    <key><util:constant static-field="org.dspace.core.Constants.COLLECTION"/></key>
                    <list>
                        <!--Introduction text-->
                        <!--<value>dc.description</value>-->
                        <!--Short description-->
                        <!--<value>dc.description.abstract</value>-->
                        <!--News-->
                        <!--<value>dc.description.tableofcontents</value>-->
                        <!--Copyright text-->
                        <value>dc.rights</value>
                        <!--Collection name-->
                        <!--<value>dc.title</value>-->
                    </list>
                </entry>
                <entry>
                    <key><util:constant static-field="org.dspace.core.Constants.ITEM"/></key>
                    <list>
                        <value>dc.description.provenance</value>
                    </list>
                </entry>
            </map>
        </property>
    </bean>

    <bean id="discovery-parent-community-1" class="org.dspace.discovery.configuration.DiscoveryConfiguration" scope="prototype">
        <property name="id" value="discovery-parent-community-1"/>
        <!--Which sidebar facets are to be displayed-->
        <property name="sidebarFacets">
            <list>
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterParentCommunity1Field" />
            </list>
        </property>
        <!-- Set TagCloud configuration per discovery configuration -->
        <property name="tagCloudFacetConfiguration" ref="scopeBasedTagCloudFacetConfiguration"/>
        <!--The search filters which can be used on the discovery search page-->
        <property name="searchFilters">
            <list>
                <ref bean="searchFilterTitle" />
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterParentCommunity1Field" />
            </list>
        </property>
        <!--The sort filters for the discovery search-->
        <property name="searchSortConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoverySortConfiguration">
                <property name="sortFields">
                    <list>
                        <ref bean="sortScore" />
                        <ref bean="sortTitle" />
                        <ref bean="sortDateIssued" />
                        <ref bean="sortDateAccessioned"/>
                    </list>
                </property>
            </bean>
        </property>
        <!--Any default filter queries, these filter queries will be used for all
            queries done by discovery for this configuration -->
        <property name="defaultFilterQueries">
            <list>
                <!--Only find items, communities and collections-->
                <value>search.resourcetype:Item OR search.resourcetype:Collection OR search.resourcetype:Community</value>
            </list>
        </property>
        <!--The configuration for the recent submissions-->
        <property name="recentSubmissionConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryRecentSubmissionsConfiguration">
                <property name="metadataSortField" value="dc.date.accessioned" />
                <property name="type" value="date"/>
                <property name="max" value="20"/>
                <!-- If enabled the collection home page will not display metadata but show a pageable list of recent submissions -->
                <property name="useAsHomePage" value="false"/>
            </bean>
        </property>
        <!--Default result per page  -->
        <property name="defaultRpp" value="10" />
        <property name="hitHighlightingConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightingConfiguration">
                <property name="metadataFields">
                    <list>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.contributor.author"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dspace.entity.type"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="person.identifier.jobtitle"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.description.abstract"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="2"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.title"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <!-- By default, full text snippets are disabled, as snippets of embargoed/restricted bitstreams
                             may appear in search results when the Item is public. See DS-3498
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.status"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.description"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        -->
                    </list>
                </property>
            </bean>
        </property>
        <property name="moreLikeThisConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryMoreLikeThisConfiguration">
                <property name="similarityMetadataFields">
                    <list>
                        <value>dc.title</value>
                        <value>dc.contributor.author</value>
                        <value>dc.creator</value>
                        <value>dc.subject</value>
                    </list>
                </property>
                <!--The minimum number of matching terms across the metadata fields above before an item is found as related -->
                <property name="minTermFrequency" value="5"/>
                <!--The maximum number of related items displayed-->
                <property name="max" value="3"/>
                <!--The minimum word length below which words will be ignored-->
                <property name="minWordLength" value="5"/>
            </bean>
        </property>
        <!-- When true a "did you mean" example will be displayed, value can be true or false -->
        <property name="spellCheckEnabled" value="true"/>
    </bean>
    <bean id="discovery-sub-community-1-1" class="org.dspace.discovery.configuration.DiscoveryConfiguration" scope="prototype">
        <property name="id" value="discovery-sub-community-1-1"/>
        <!--Which sidebar facets are to be displayed-->
        <property name="sidebarFacets">
            <list>
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterSubCommunity11Field" />
            </list>
        </property>
        <!-- Set TagCloud configuration per discovery configuration -->
        <property name="tagCloudFacetConfiguration" ref="scopeBasedTagCloudFacetConfiguration"/>
        <!--The search filters which can be used on the discovery search page-->
        <property name="searchFilters">
            <list>
                <ref bean="searchFilterTitle" />
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterSubCommunity11Field" />
            </list>
        </property>
        <!--The sort filters for the discovery search-->
        <property name="searchSortConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoverySortConfiguration">
                <property name="sortFields">
                    <list>
                        <ref bean="sortScore" />
                        <ref bean="sortTitle" />
                        <ref bean="sortDateIssued" />
                        <ref bean="sortDateAccessioned"/>
                    </list>
                </property>
            </bean>
        </property>
        <!--Any default filter queries, these filter queries will be used for all
            queries done by discovery for this configuration -->
        <property name="defaultFilterQueries">
            <list>
                <!--Only find items, communities and collections-->
                <value>search.resourcetype:Item OR search.resourcetype:Collection OR search.resourcetype:Community</value>
            </list>
        </property>
        <!--The configuration for the recent submissions-->
        <property name="recentSubmissionConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryRecentSubmissionsConfiguration">
                <property name="metadataSortField" value="dc.date.accessioned" />
                <property name="type" value="date"/>
                <property name="max" value="20"/>
                <!-- If enabled the collection home page will not display metadata but show a pageable list of recent submissions -->
                <property name="useAsHomePage" value="false"/>
            </bean>
        </property>
        <!--Default result per page  -->
        <property name="defaultRpp" value="10" />
        <property name="hitHighlightingConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightingConfiguration">
                <property name="metadataFields">
                    <list>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.contributor.author"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dspace.entity.type"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="person.identifier.jobtitle"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.description.abstract"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="2"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.title"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <!-- By default, full text snippets are disabled, as snippets of embargoed/restricted bitstreams
                             may appear in search results when the Item is public. See DS-3498
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.status"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.description"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        -->
                    </list>
                </property>
            </bean>
        </property>
        <property name="moreLikeThisConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryMoreLikeThisConfiguration">
                <property name="similarityMetadataFields">
                    <list>
                        <value>dc.title</value>
                        <value>dc.contributor.author</value>
                        <value>dc.creator</value>
                        <value>dc.subject</value>
                    </list>
                </property>
                <!--The minimum number of matching terms across the metadata fields above before an item is found as related -->
                <property name="minTermFrequency" value="5"/>
                <!--The maximum number of related items displayed-->
                <property name="max" value="3"/>
                <!--The minimum word length below which words will be ignored-->
                <property name="minWordLength" value="5"/>
            </bean>
        </property>
        <!-- When true a "did you mean" example will be displayed, value can be true or false -->
        <property name="spellCheckEnabled" value="true"/>
    </bean>

    <bean id="discovery-collection-1-1-1" class="org.dspace.discovery.configuration.DiscoveryConfiguration" scope="prototype">
        <property name="id" value="discovery-collection-1-1-1"/>
        <!--Which sidebar facets are to be displayed-->
        <property name="sidebarFacets">
            <list>
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterCollection111Field" />
            </list>
        </property>
        <!-- Set TagCloud configuration per discovery configuration -->
        <property name="tagCloudFacetConfiguration" ref="scopeBasedTagCloudFacetConfiguration"/>
        <!--The search filters which can be used on the discovery search page-->
        <property name="searchFilters">
            <list>
                <ref bean="searchFilterTitle" />
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterCollection111Field" />
            </list>
        </property>
        <!--The sort filters for the discovery search-->
        <property name="searchSortConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoverySortConfiguration">
                <property name="sortFields">
                    <list>
                        <ref bean="sortScore" />
                        <ref bean="sortTitle" />
                        <ref bean="sortDateIssued" />
                        <ref bean="sortDateAccessioned"/>
                    </list>
                </property>
            </bean>
        </property>
        <!--Any default filter queries, these filter queries will be used for all
            queries done by discovery for this configuration -->
        <property name="defaultFilterQueries">
            <list>
                <!--Only find items, communities and collections-->
                <value>search.resourcetype:Item OR search.resourcetype:Collection OR search.resourcetype:Community</value>
            </list>
        </property>
        <!--The configuration for the recent submissions-->
        <property name="recentSubmissionConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryRecentSubmissionsConfiguration">
                <property name="metadataSortField" value="dc.date.accessioned" />
                <property name="type" value="date"/>
                <property name="max" value="20"/>
                <!-- If enabled the collection home page will not display metadata but show a pageable list of recent submissions -->
                <property name="useAsHomePage" value="false"/>
            </bean>
        </property>
        <!--Default result per page  -->
        <property name="defaultRpp" value="10" />
        <property name="hitHighlightingConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightingConfiguration">
                <property name="metadataFields">
                    <list>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.contributor.author"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dspace.entity.type"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="person.identifier.jobtitle"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.description.abstract"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="2"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.title"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <!-- By default, full text snippets are disabled, as snippets of embargoed/restricted bitstreams
                             may appear in search results when the Item is public. See DS-3498
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.status"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.description"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        -->
                    </list>
                </property>
            </bean>
        </property>
        <property name="moreLikeThisConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryMoreLikeThisConfiguration">
                <property name="similarityMetadataFields">
                    <list>
                        <value>dc.title</value>
                        <value>dc.contributor.author</value>
                        <value>dc.creator</value>
                        <value>dc.subject</value>
                    </list>
                </property>
                <!--The minimum number of matching terms across the metadata fields above before an item is found as related -->
                <property name="minTermFrequency" value="5"/>
                <!--The maximum number of related items displayed-->
                <property name="max" value="3"/>
                <!--The minimum word length below which words will be ignored-->
                <property name="minWordLength" value="5"/>
            </bean>
        </property>
        <!-- When true a "did you mean" example will be displayed, value can be true or false -->
        <property name="spellCheckEnabled" value="true"/>
    </bean>
    <bean id="discovery-collection-1-2-1" class="org.dspace.discovery.configuration.DiscoveryConfiguration" scope="prototype">
        <property name="id" value="discovery-collection-1-2-1"/>
        <!--Which sidebar facets are to be displayed-->
        <property name="sidebarFacets">
            <list>
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterCollection121Field" />
            </list>
        </property>
        <!-- Set TagCloud configuration per discovery configuration -->
        <property name="tagCloudFacetConfiguration" ref="scopeBasedTagCloudFacetConfiguration"/>
        <!--The search filters which can be used on the discovery search page-->
        <property name="searchFilters">
            <list>
                <ref bean="searchFilterTitle" />
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterCollection121Field" />
            </list>
        </property>
        <!--The sort filters for the discovery search-->
        <property name="searchSortConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoverySortConfiguration">
                <property name="sortFields">
                    <list>
                        <ref bean="sortScore" />
                        <ref bean="sortTitle" />
                        <ref bean="sortDateIssued" />
                        <ref bean="sortDateAccessioned"/>
                    </list>
                </property>
            </bean>
        </property>
        <!--Any default filter queries, these filter queries will be used for all
            queries done by discovery for this configuration -->
        <property name="defaultFilterQueries">
            <list>
                <!--Only find items, communities and collections-->
                <value>search.resourcetype:Item OR search.resourcetype:Collection OR search.resourcetype:Community</value>
            </list>
        </property>
        <!--The configuration for the recent submissions-->
        <property name="recentSubmissionConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryRecentSubmissionsConfiguration">
                <property name="metadataSortField" value="dc.date.accessioned" />
                <property name="type" value="date"/>
                <property name="max" value="20"/>
                <!-- If enabled the collection home page will not display metadata but show a pageable list of recent submissions -->
                <property name="useAsHomePage" value="false"/>
            </bean>
        </property>
        <!--Default result per page  -->
        <property name="defaultRpp" value="10" />
        <property name="hitHighlightingConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightingConfiguration">
                <property name="metadataFields">
                    <list>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.contributor.author"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dspace.entity.type"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="person.identifier.jobtitle"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.description.abstract"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="2"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.title"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <!-- By default, full text snippets are disabled, as snippets of embargoed/restricted bitstreams
                             may appear in search results when the Item is public. See DS-3498
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.status"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.description"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        -->
                    </list>
                </property>
            </bean>
        </property>
        <property name="moreLikeThisConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryMoreLikeThisConfiguration">
                <property name="similarityMetadataFields">
                    <list>
                        <value>dc.title</value>
                        <value>dc.contributor.author</value>
                        <value>dc.creator</value>
                        <value>dc.subject</value>
                    </list>
                </property>
                <!--The minimum number of matching terms across the metadata fields above before an item is found as related -->
                <property name="minTermFrequency" value="5"/>
                <!--The maximum number of related items displayed-->
                <property name="max" value="3"/>
                <!--The minimum word length below which words will be ignored-->
                <property name="minWordLength" value="5"/>
            </bean>
        </property>
        <!-- When true a "did you mean" example will be displayed, value can be true or false -->
        <property name="spellCheckEnabled" value="true"/>
    </bean>

    <bean id="discovery-sub-community-2-1" class="org.dspace.discovery.configuration.DiscoveryConfiguration" scope="prototype">
        <property name="id" value="discovery-sub-community-2-1"/>
        <!--Which sidebar facets are to be displayed-->
        <property name="sidebarFacets">
            <list>
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterSubCommunity21Field" />
            </list>
        </property>
        <!-- Set TagCloud configuration per discovery configuration -->
        <property name="tagCloudFacetConfiguration" ref="scopeBasedTagCloudFacetConfiguration"/>
        <!--The search filters which can be used on the discovery search page-->
        <property name="searchFilters">
            <list>
                <ref bean="searchFilterTitle" />
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterSubCommunity21Field" />
            </list>
        </property>
        <!--The sort filters for the discovery search-->
        <property name="searchSortConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoverySortConfiguration">
                <property name="sortFields">
                    <list>
                        <ref bean="sortScore" />
                        <ref bean="sortTitle" />
                        <ref bean="sortDateIssued" />
                        <ref bean="sortDateAccessioned"/>
                    </list>
                </property>
            </bean>
        </property>
        <!--Any default filter queries, these filter queries will be used for all
            queries done by discovery for this configuration -->
        <property name="defaultFilterQueries">
            <list>
                <!--Only find items, communities and collections-->
                <value>search.resourcetype:Item OR search.resourcetype:Collection OR search.resourcetype:Community</value>
            </list>
        </property>
        <!--The configuration for the recent submissions-->
        <property name="recentSubmissionConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryRecentSubmissionsConfiguration">
                <property name="metadataSortField" value="dc.date.accessioned" />
                <property name="type" value="date"/>
                <property name="max" value="20"/>
                <!-- If enabled the collection home page will not display metadata but show a pageable list of recent submissions -->
                <property name="useAsHomePage" value="false"/>
            </bean>
        </property>
        <!--Default result per page  -->
        <property name="defaultRpp" value="10" />
        <property name="hitHighlightingConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightingConfiguration">
                <property name="metadataFields">
                    <list>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.contributor.author"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dspace.entity.type"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="person.identifier.jobtitle"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.description.abstract"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="2"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.title"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <!-- By default, full text snippets are disabled, as snippets of embargoed/restricted bitstreams
                             may appear in search results when the Item is public. See DS-3498
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.status"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.description"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        -->
                    </list>
                </property>
            </bean>
        </property>
        <property name="moreLikeThisConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryMoreLikeThisConfiguration">
                <property name="similarityMetadataFields">
                    <list>
                        <value>dc.title</value>
                        <value>dc.contributor.author</value>
                        <value>dc.creator</value>
                        <value>dc.subject</value>
                    </list>
                </property>
                <!--The minimum number of matching terms across the metadata fields above before an item is found as related -->
                <property name="minTermFrequency" value="5"/>
                <!--The maximum number of related items displayed-->
                <property name="max" value="3"/>
                <!--The minimum word length below which words will be ignored-->
                <property name="minWordLength" value="5"/>
            </bean>
        </property>
        <!-- When true a "did you mean" example will be displayed, value can be true or false -->
        <property name="spellCheckEnabled" value="true"/>
    </bean>
    <bean id="discovery-collection-2-1-1" class="org.dspace.discovery.configuration.DiscoveryConfiguration" scope="prototype">
        <property name="id" value="discovery-collection-2-1-1"/>
        <!--Which sidebar facets are to be displayed-->
        <property name="sidebarFacets">
            <list>
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterCollection211Field" />
            </list>
        </property>
        <!-- Set TagCloud configuration per discovery configuration -->
        <property name="tagCloudFacetConfiguration" ref="scopeBasedTagCloudFacetConfiguration"/>
        <!--The search filters which can be used on the discovery search page-->
        <property name="searchFilters">
            <list>
                <ref bean="searchFilterTitle" />
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterCollection211Field" />
            </list>
        </property>
        <!--The sort filters for the discovery search-->
        <property name="searchSortConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoverySortConfiguration">
                <property name="sortFields">
                    <list>
                        <ref bean="sortScore" />
                        <ref bean="sortTitle" />
                        <ref bean="sortDateIssued" />
                        <ref bean="sortDateAccessioned"/>
                    </list>
                </property>
            </bean>
        </property>
        <!--Any default filter queries, these filter queries will be used for all
            queries done by discovery for this configuration -->
        <property name="defaultFilterQueries">
            <list>
                <!--Only find items, communities and collections-->
                <value>search.resourcetype:Item OR search.resourcetype:Collection OR search.resourcetype:Community</value>
            </list>
        </property>
        <!--The configuration for the recent submissions-->
        <property name="recentSubmissionConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryRecentSubmissionsConfiguration">
                <property name="metadataSortField" value="dc.date.accessioned" />
                <property name="type" value="date"/>
                <property name="max" value="20"/>
                <!-- If enabled the collection home page will not display metadata but show a pageable list of recent submissions -->
                <property name="useAsHomePage" value="false"/>
            </bean>
        </property>
        <!--Default result per page  -->
        <property name="defaultRpp" value="10" />
        <property name="hitHighlightingConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightingConfiguration">
                <property name="metadataFields">
                    <list>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.contributor.author"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dspace.entity.type"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="person.identifier.jobtitle"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.description.abstract"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="2"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.title"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <!-- By default, full text snippets are disabled, as snippets of embargoed/restricted bitstreams
                             may appear in search results when the Item is public. See DS-3498
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.status"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.description"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        -->
                    </list>
                </property>
            </bean>
        </property>
        <property name="moreLikeThisConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryMoreLikeThisConfiguration">
                <property name="similarityMetadataFields">
                    <list>
                        <value>dc.title</value>
                        <value>dc.contributor.author</value>
                        <value>dc.creator</value>
                        <value>dc.subject</value>
                    </list>
                </property>
                <!--The minimum number of matching terms across the metadata fields above before an item is found as related -->
                <property name="minTermFrequency" value="5"/>
                <!--The maximum number of related items displayed-->
                <property name="max" value="3"/>
                <!--The minimum word length below which words will be ignored-->
                <property name="minWordLength" value="5"/>
            </bean>
        </property>
        <!-- When true a "did you mean" example will be displayed, value can be true or false -->
        <property name="spellCheckEnabled" value="true"/>
    </bean>
    <bean id="discovery-collection-2-2-1" class="org.dspace.discovery.configuration.DiscoveryConfiguration" scope="prototype">
        <property name="id" value="discovery-collection-2-2-1"/>
        <!--Which sidebar facets are to be displayed-->
        <property name="sidebarFacets">
            <list>
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterCollection221Field" />
            </list>
        </property>
        <!-- Set TagCloud configuration per discovery configuration -->
        <property name="tagCloudFacetConfiguration" ref="scopeBasedTagCloudFacetConfiguration"/>
        <!--The search filters which can be used on the discovery search page-->
        <property name="searchFilters">
            <list>
                <ref bean="searchFilterTitle" />
                <ref bean="searchFilterAuthor" />
                <ref bean="searchFilterCollection221Field" />
            </list>
        </property>
        <!--The sort filters for the discovery search-->
        <property name="searchSortConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoverySortConfiguration">
                <property name="sortFields">
                    <list>
                        <ref bean="sortScore" />
                        <ref bean="sortTitle" />
                        <ref bean="sortDateIssued" />
                        <ref bean="sortDateAccessioned"/>
                    </list>
                </property>
            </bean>
        </property>
        <!--Any default filter queries, these filter queries will be used for all
            queries done by discovery for this configuration -->
        <property name="defaultFilterQueries">
            <list>
                <!--Only find items, communities and collections-->
                <value>search.resourcetype:Item OR search.resourcetype:Collection OR search.resourcetype:Community</value>
            </list>
        </property>
        <!--The configuration for the recent submissions-->
        <property name="recentSubmissionConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryRecentSubmissionsConfiguration">
                <property name="metadataSortField" value="dc.date.accessioned" />
                <property name="type" value="date"/>
                <property name="max" value="20"/>
                <!-- If enabled the collection home page will not display metadata but show a pageable list of recent submissions -->
                <property name="useAsHomePage" value="false"/>
            </bean>
        </property>
        <!--Default result per page  -->
        <property name="defaultRpp" value="10" />
        <property name="hitHighlightingConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightingConfiguration">
                <property name="metadataFields">
                    <list>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.contributor.author"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dspace.entity.type"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="person.identifier.jobtitle"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.description.abstract"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="2"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="dc.title"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <!-- By default, full text snippets are disabled, as snippets of embargoed/restricted bitstreams
                             may appear in search results when the Item is public. See DS-3498
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="project.identifier.status"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.name"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        <bean class="org.dspace.discovery.configuration.DiscoveryHitHighlightFieldConfiguration">
                            <property name="field" value="orgunit.identifier.description"/>
                            <property name="maxSize" value="250"/>
                            <property name="snippets" value="5"/>
                        </bean>
                        -->
                    </list>
                </property>
            </bean>
        </property>
        <property name="moreLikeThisConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryMoreLikeThisConfiguration">
                <property name="similarityMetadataFields">
                    <list>
                        <value>dc.title</value>
                        <value>dc.contributor.author</value>
                        <value>dc.creator</value>
                        <value>dc.subject</value>
                    </list>
                </property>
                <!--The minimum number of matching terms across the metadata fields above before an item is found as related -->
                <property name="minTermFrequency" value="5"/>
                <!--The maximum number of related items displayed-->
                <property name="max" value="3"/>
                <!--The minimum word length below which words will be ignored-->
                <property name="minWordLength" value="5"/>
            </bean>
        </property>
        <!-- When true a "did you mean" example will be displayed, value can be true or false -->
        <property name="spellCheckEnabled" value="true"/>
    </bean>

    <bean id="scopeBasedTagCloudFacetConfiguration" class="org.dspace.discovery.configuration.TagCloudFacetConfiguration">
        <!-- Actual configuration of the tagcloud (colors, sorting, etc.) -->
        <property name="tagCloudConfiguration" ref="tagCloudConfiguration"/>
        <!-- List of tagclouds to appear, one for every search filter, one after the other -->
        <property name="tagCloudFacets">
            <list>
                <ref bean="searchFilterAuthor" />
            </list>
        </property>
    </bean>

    <bean id="searchFilterParentCommunity1Field" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="parentcommunity1field"/>
        <property name="metadataFields">
            <list>
                <value>dc.test.parentcommunity1field</value>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>

    <bean id="searchFilterSubCommunity11Field" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="subcommunity11field"/>
        <property name="metadataFields">
            <list>
                <value>dc.test.subcommunity11field</value>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>

    <bean id="searchFilterCollection111Field" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="collection111field"/>
        <property name="metadataFields">
            <list>
                <value>dc.test.collection111field</value>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>

    <bean id="searchFilterCollection121Field" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="collection121field"/>
        <property name="metadataFields">
            <list>
                <value>dc.test.collection121field</value>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>

    <bean id="searchFilterSubCommunity21Field" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="subcommunity21field"/>
        <property name="metadataFields">
            <list>
                <value>dc.test.subcommunity21field</value>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>
    <bean id="searchFilterCollection211Field" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="collection211field"/>
        <property name="metadataFields">
            <list>
                <value>dc.test.collection211field</value>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>
    <bean id="searchFilterCollection221Field" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="collection221field"/>
        <property name="metadataFields">
            <list>
                <value>dc.test.collection221field</value>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>

    <bean id="ldnMessageEntityBaseConfig"
          class="org.dspace.discovery.configuration.DiscoveryConfiguration"
          scope="prototype">
        <property name="id" value="ldnMessages" />
        <!--Which sidebar facets are to be displayed -->
        <property name="sidebarFacets">
            <list>
                <ref bean="searchFilterNotifyRelatedItem" />
                <ref bean="searchFilterNotifyOrigin" />
                <ref bean="searchFilterNotifyTarget" />
                <ref bean="searchFilterNotifyQueueStatus" />
                <ref bean="searchFilterNotifyActivityStreamType" />
                <ref bean="searchFilterNotifyCoarNotifyType" />
                <ref bean="searchFilterNotifyNotificationType" />
            </list>
        </property>
        <!--The search filters which can be used on the discovery search page -->
        <property name="searchFilters">
            <list>
                <ref bean="searchFilterNotifyRelatedItem" />
                <ref bean="searchFilterNotifyOrigin" />
                <ref bean="searchFilterNotifyTarget" />
                <ref bean="searchFilterNotifyQueueStatus" />
                <ref bean="searchFilterNotifyActivityStreamType" />
                <ref bean="searchFilterNotifyCoarNotifyType" />
                <ref bean="searchFilterNotifyNotificationType" />
            </list>
        </property>
        <!--The sort filters for the discovery search-->
        <property name="searchSortConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoverySortConfiguration">
                <property name="sortFields">
                    <list>
                        <ref bean="sortLastModified"/>
                        <ref bean="sortLastModifiedAsc"/>
                        <ref bean="sortQueueLastStartTimeDesc"/>
                        <ref bean="sortQueueLastStartTimeAsc"/>
                        <ref bean="sortQueueAttemptsDesc"/>
                        <ref bean="sortQueueAttemptsAsc"/>
                    </list>
                </property>
            </bean>
        </property>
        <!--Any default filter queries, these filter queries will be used for all
            queries done by discovery for this configuration -->
        <property name="defaultFilterQueries">
            <list>
                <!--Only find LDNMessageEntity -->
                <value>search.resourcetype:LDNMessageEntity</value>
            </list>
        </property>
        <!--Default result per page  -->
        <property name="defaultRpp" value="10" />
    </bean>

    <bean id="NOTIFY.incoming" class="org.dspace.discovery.configuration.DiscoveryConfiguration" scope="prototype" parent="ldnMessageEntityBaseConfig">
        <property name="id" value="NOTIFY.incoming"/>
        <property name="defaultFilterQueries">
            <list>
                <!--Only find LDNMessageEntity -->
                <value>search.resourcetype:LDNMessageEntity</value>
                <value>notification_type_keyword:#{T(org.dspace.app.ldn.LDNMessageEntity).TYPE_INCOMING}</value>
            </list>
        </property>
    </bean>

    <bean id="NOTIFY.outgoing" class="org.dspace.discovery.configuration.DiscoveryConfiguration" scope="prototype" parent="ldnMessageEntityBaseConfig">
        <property name="id" value="NOTIFY.outgoing"/>
        <property name="defaultFilterQueries">
            <list>
                <!--Only find LDNMessageEntity -->
                <value>search.resourcetype:LDNMessageEntity</value>
                <value>notification_type_keyword:#{T(org.dspace.app.ldn.LDNMessageEntity).TYPE_OUTGOING}</value>
            </list>
        </property>
    </bean>

    <bean id="searchFilterNotifyRelatedItem" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="relateditem"/>
        <property name="metadataFields">
            <list>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>

    <bean id="searchFilterNotifyOrigin" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="origin"/>
        <property name="metadataFields">
            <list>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>

    <bean id="searchFilterNotifyTarget" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="target"/>
        <property name="metadataFields">
            <list>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>

    <bean id="searchFilterNotifyQueueStatus" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="queue_status"/>
        <property name="metadataFields">
            <list>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>

    <bean id="searchFilterNotifyActivityStreamType" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="activity_stream_type"/>
        <property name="metadataFields">
            <list>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>

    <bean id="searchFilterNotifyCoarNotifyType" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="coar_notify_type"/>
        <property name="metadataFields">
            <list>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>

    <bean id="searchFilterNotifyNotificationType" class="org.dspace.discovery.configuration.DiscoverySearchFilterFacet">
        <property name="indexFieldName" value="notification_type"/>
        <property name="metadataFields">
            <list>
            </list>
        </property>
        <property name="facetLimit" value="5"/>
        <property name="sortOrderSidebar" value="COUNT"/>
        <property name="sortOrderFilterPage" value="COUNT"/>
        <property name="isOpenByDefault" value="true"/>
        <property name="pageSize" value="10"/>
        <property name="exposeMinAndMaxValue" value="true"/>
    </bean>


</beans>
