sf_store

This bundle contains factories for two kinds of stores:

  1. DocumentStore
  2. SuggestStore

The SuggestStore is required while typing a search term into a search box. It responds with a list of suggestions for this search term.

The DocumentStore is used for requesting all results matching a specific search expression.

Configuration

Defining the store instances

In the app.json file you can configure any number of SuggestStore and DocumentStore instances.

Each SuggestStore and DocumentStore configuration must have the following properties:

Property Name Type Description
id String An identifier for the store. The value must be unique among all stores registered in the app.
target String The URL of the search service followed by the smart.finder core name, e.g. https://demos.conterra.de/ct-finder-server-webapp-2.0.9/core0

Additionally, a SuggestStore must also have a title attribute.

Property Name Type Description
title String The title of the store as displayed in the select box in OmniSearch.

Example

Here is an example for a complete store configuration:

"sf_store": {
  "SuggestStore": [
    {
      "id": "core0_suggest_store",
      "title": "smart.finder Suchindex",
      "target": "https://demos.conterra.de/ct-finder-server-webapp-1.6.0/core0"
    },
    {
      "id": "isoCore_suggest_store",
      "title": "smart.finder SDI Suchindex",
      "target": "https://demos.conterra.de/ct-finder-server-webapp-1.6.0/iso"
    }
  ],
  "DocumentStore": [
    {
      "id": "core0_store",
      "target": "https://demos.conterra.de/ct-finder-server-webapp-1.6.0/core0"
    },
    {
      "id": "isoCore_store",
      "target": "https://demos.conterra.de/ct-finder-server-webapp-1.6.0/iso"
    }
  ]
}

You can define the attributes that are displayed in the filter on the left hand side of the results page.

You can configure the attribute filter for each smart.finder core separately. In your app.json file look for the DocumentStore instance that points to the desired smart.finder core. Then edit the facetFields property and list the fields you wish to appear in the filter.

Property Name Type Description
facetFields Array<String> A list of field names you wish to appear in the attribute filter.

Example:

"sf_store": {
  "SuggestStore": [
    ...
  ],
  "DocumentStore": [
    {
      "id": "core0_store",
      "target": "https://demos.conterra.de/ct-finder-server-webapp-1.6,
      "facetFields": ["publisher","language","type","format", "accessRights"],
    },
    ...
  ]
}

Configuring the spatial reference system for data with geometry

Usually each metadata record has a certain geometry. By default, it is assumed that these geometries use the spatial reference system with the ID EPSG:4326 (see https://epsg.io/4326). However, if your geometry records have coordinates in a different spatial reference system, you run into issues when performing spatial queries and displaying your metadata on a map.

In such cases, you need to tell the DocumentStore component the correct spatial reference by specifying the spatial reference's EPSG code in the spatialReferenceWkidOfGeometriesInIndex property. For example, if your geometry data is stored in the index in the coordinate system DHDN / 3-degree Gauss-Kruger zone 2, specify 31466 (see https://epsg.io/31466).

Property Name Type Default value Description
spatialReferenceWkidOfGeometriesInIndex Number 4326 The EPSG code of the spatial reference system of the geometries in the index.