Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Property:

search.server

Example Value:

search.server=http://localhost:8080/solr/search

Informational Note:

Discovery relies on a SOLR index for storage and retrieval of its information. This parameter determines the location of the SOLR index.

Property:

search.default.sort.order

Example Value:

search.default.sort.order=DESC

Informational Note:

The default sort order for relevance when searching in discovery. This parameter can either be descending (DESC) or ascending (ASC). End-users can change this sort order from the user interface.

Property:

index.ignore

Example Value:

index.ignore=dc.description.provenance,dc.language

Informational Note:

By default, Discovery will include all of the DSpace metadata in its search index. In cases where specific metadata is confidential, repository managers can include those fields by adding them to this comma separated list.

Configuring the Discovery user interface (config/spring/spring-dspace-addon-discovery-configuration-services.xml)

The spring-dspace-addon-discovery-configuration-services.xml file is located in the dspace.dir/config/spring directory.

Introduction to XML configuration of beans

Because this file is in XML format, you should be familiar with XML before editing this file. The configurations are organized together in beans, depending on what these properties are used for.

Structure

Code Block
langxml
<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"
    xsi:schemaLocation="http://www.springframework.org/schema/beans
           http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
           http://www.springframework.org/schema/context
           http://www.springframework.org/schema/context/spring-context-2.5.xsd"
    default-autowire-candidates="*Service,*DAO,javax.sql.DataSource">
    <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>
            <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" />
                        ......
            </map>
        </property>
    </bean>


<bean id="defaultConfiguration" class="org.dspace.discovery.configuration.DiscoveryConfiguration" scope="prototype">
        <!--Which sidebar facets are to be displayed-->
        <property name="sidebarFacets">
            <list>
            </list>
        </property>
        <!--The search filters which can be used on the discovery search page-->
        <property name="searchFilters">
            <list>
            ....
            </list>
        </property>
        <!--The sort filters for the discovery search-->
        <property name="searchSortFields">
            <list>
            ....
            </list>
        </property>
        <!--Any default filter queries, these filter queries will be used for all queries done by discovery for this configuration-->
        <!--<property name="defaultFilterQueries">-->
            <!--<list>-->
            ....
            <!--</list>-->
        <!--</property>-->
        <!--The configuration for the recent submissions-->
        <property name="recentSubmissionConfiguration">
            <bean class="org.dspace.discovery.configuration.DiscoveryRecentSubmissionsConfiguration">
             ...
            </bean>
        </property>
    </bean>

Default user interface customization

By default, this file contains the "defaultConfiguration" for discovery which contains the following settings:

  • Sidebar facets configured:
    • sidebarFacetAuthor:  contains the metadata fields dc.contributor.author & dc.creator with a facet limit of 10 and sorted by count
    • sidebarFacetSubject: contains all subject metadata fields (dc.subject.*) with a facet limit of 10 and sorted by count
    • sidebarFacetDateIssued: contains the dc.date.issued metadata field has a type "date" and is sorted by value
  • The configured search filters:
    • searchFilterTitle: contains the dc.title metadata field and has a tokenized autocomplete
    • searchFilterAuthor: contains the dc.contributor.author & dc.creator metadata fields and has a non tokenized autocomplete configured
    • searchFilterSubject: contains the dc.subject.* metadata fields and has a non tokenized autocomplete configured
    • searchFilterIssued: contains the dc.date.issued metadata field with the type "date" and has a tokenized autocomplete
  • The configured sort fields:
    • sortTitle: contains the dc.title metadata field
    • sortDateIssued: contains the dc.date.issued metadata field, this sort has the type date configured.
  • The default filter queries are disabled by default but there is an example in the default configuration in comments which allows discovery to only return items (as opposed to also communities/collections).
  • The recent submissions configuration is sorted by dc.date. accessioned which is a date and a maximum number of 5 recent submissions are displayed.

Many of the properties contain lists which use references to point to the configuration elements. This way a certain configuration type can be used in multiple discovery configurations so there is no need to duplicate these.

Advanced SOLR Configuration

...