Global Search Configuration

Feedback


SuperMap iPortal provides a global search function that allows you to search all resources in the portal without searching in each resource category individually. iPortal global search function relies on the Elasticsearch distributed search engine. For the use of the global search, please see: gloabal search.

Global search configuration

An ElasticSearch search server is built into the SuperMap iPortal package to provide global search capabilities. The built-in global search is enabled by default when you start the iPortal service, and you can use it directly or change the default configuration of the built-in global search (e.g. port number, cluster name, etc.) to suit your actual production environment. The advantage of the built-in global search is that it is simple to use and is suitable for small portal sites.

If iPortal built-in global search does not meet your business needs, you can use your own standalone Elasticsearch search server, which can be configured as follows:

  1. Open the search-beans.xml configuration file in the %SuperMap iPortal_HOME%/webapps/iportal/WEB-INF/config/search/WEB-INF directory and change the parameters according to the Elasticsearch server you have deployed.

<bean id="esSetting" class="com.supermap.iportal.search.commontypes.ESSetting">

    <property name="address" value="127.0.0.1"></property>

    <property name="port" value="9310"></property>  

    <property name="clusterName" value="myapplication"></property>

    <!-- <property name="nodeName" value="node1"></property> -->

    <property name="indexName" value="portalsearch"></property>

    <property name="numberOfShards" value="5"></property>

    <property name="numberOfReplicas" value="0"></property>

</bean>

  1. Modify the iportal.xml configuration file in the %SuperMap iPortal_HOME%/webapps/iportal/WEB-INF directory with the following configuration items:

<IportalConfig>

  ...

  <modulesConfig>

    <searchModuleConfig class="com.supermap.server.config.BuildinSearchConfig">

      <enable>true</enable>

      <reindexAllResources>true</reindexAllResources>

      <startElasticSearch>true</startElasticSearch>

      <port>8192</port>

    </searchModuleConfig>

  </modulesConfig>

  ...

</IportalConfig>

Once the configuration above is complete, restart iPortal to take effect.

Geographical bound search configuration

In SuperMap iPortal, you can enter the latitude and longitude coordinates of the lower left and upper right vertices in the "Bounds" input box, or draw a rectangular area in the map window that pops up after clicking the icon to set geographic bounds as a search criterion to search the resources which match the geographic bounds set.

It should be noted that the iPortal administrator needs to configure the base map used for the geographical bound search before it can be used, in order to activate the ability to set geographic bounds. The same configuration items apply to the geographical bound search as to the spatial scope permissions control, for which you can refer to the spatial scope permissions map configuration.