How to Map Metadata Property Values: Property Mapper
What is the Property Mapper Pipeline Stage?
The Property Mapper is a pipeline stage Pipeline stages offer uniformity to the end user. Various functions include mapping names and values to match local refinements. available from the list of SmartHub pipeline stages.
- For information about SmartHub Pipeline stages, see About Pipeline Stages.
The Property Mapper is used by all SmartHub backends such as Elasticsearch, SharePoint, Solr, and others.
Use the Property Mapper pipeline stage configuration to translate the name of a managed property to the name of an existing property on a specific search engine The search engine your SmartHub instance uses to perform queries. SmartHub can be configured to use more than one search engine. (backend The search engine your SmartHub instance uses to perform queries. SmartHub can be configured to use more than one search engine.) such as Elasticsearch or SharePoint Online.
See the figures below and the section "Property Mapping Example" lower down on this page.
Problem: Properties by Different Names Across SmartHub Backends
Solution: SmartHub Property Mapping
Property Mapper Parameters
[LocalPropertyName,RemotePropertyName;]*
This stage must be added as both a Query and Results pipeline stage to each search engine (backend).
Default Properties
By default, the properties below are required regardless of which backend (search engine) your environment uses.
- date
- filetype
- clickUri
- author
- excerpt
- title
Property Mapping Example
In this example the following conditions exist:
- Your search index stores document file extensions in a property named
escbase_fileextension
- Your search interface expects a property named
FileExtension
. - To apply a refiner or run a query that returns a file with a specific extension, you must map the
FileExtension
property from the UI to theescbase_fileextension
property in the index.
User Interface Property |
|
Property stored in Search Index | Property Type (must be the same for both properties being mapped) |
---|---|---|---|
|
------> | escbase_fileextension
|
String |
Example Index
The search index (backend) in this example contains the following properties:
- ElasticDocumentUrl
- escbase_fileextension: This is the only property mapped in this specific example.
- escbase_class
- ElastsicDocumentAuthor
Example Query
To map the properties in this example correctly, you must specify the following Property Mapper configuration:
FileExtension,escbase_fileextension
- To map the properties correctly, verify that the property types are the same:
string
tostring
integer
tointeger
- and so on.
- If the
RemotePropertyName
is empty, theLocalPropertyName
is removed from the query.- This removal does not affect the returned results.
Query Parameters Modified by Property Mapper Stage
This pipeline stage modifies the following query parameters:
QueryText
- Not case sensitive.
- When the query contains
LocalPropertyName:value
, the query is transformed toRemotePropertyName:value
. - If the local property is mapped to
empty
, the property is not removed from the query text, so that the backend can return a warning message to the user and does not return any results.
SelectProperties
- Not case sensitive.
- When the
LocalPropertyName
is requested as a property for each search result, this property is removed from the requested properties andRemotePropertyName
is requested instead.
SortList
- Not case sensitive.
- Maps
SortBy
properties. - If the local property is mapped to
empty
, the sort property is not removed from the query, so that the backend can return a warning message.
Refiners
- Not case sensitive.
- Maps the requested refiners.
RefinementFilters
- Not case sensitive.
- Go to Query Refinement in SharePoint.
CustomRefinementIntervals
- Not case sensitive.
- Go to the
KeywordQuery.CustomRefinementIntervals
property.