Toggle menu

Geospatial Import End Points

A geospatial import End Point is responsible importing geospatial data into the iCM database to improve the performance of the geospatial search End Points.

Namespace

By convention, all geospatial import End Points must be named import and must be created under the root namespace; goss.geospatial.layers. As it is not possible to create multiple End Points with the name import in the same folder, and to assist with categorisation, further subfolders should be used to categorise and name the import End Points. The full namespace of a geospatial import End Point should be goss.geospatial.layers.category.name.import, where category and name should be replaced as required.

For example, the following shows an example of a National Parks import End Point that has been categorised under Environment.

Geospatial Import End Point Namespace
 

Input Schema

A geospatial import End Point should not require an input parameter schema.

End Point Script

The purpose of a geospatial import End Point is to import GeoJSON data into the iCM database for a particular layer and import region. A common use case is to import an entire geospatial dataset, which may set the import region as the full globe. Importing data against the full globe means that any request to the search End Point of the same layer will always return data from a valid database import. Other use cases may only require smaller import regions.

The import End Points provided as out of the box examples follow the full globe use case, and include the following steps:

  1. Retrieve the full dataset from the original data source (this could be a 3rd party API, CSV file, iCM article data... anywhere!)
  2. Convert the original source data to GeoJSON
  3. Import the data into the iCM database against the layer and the full globe region

Note: As import End Points will commonly be called asynchronously or via a schedule, a specific return schema is not mandated

Take a look at the Geospatial Layer Search Helper documentation, which provides useful functions for developing geospatial import End Points.

Scheduling Imports

It is possible to schedule import End Points to run on a schedule using the Scheduled Tasks in iCM. Care should be taken to ensure a recurring schedule fits with the configured import TTL for each layer, for example if a layer has been configured to hold import data for 7 days, the schedule should be set to run at least every 7 days to ensure there is no loss of search performance.

Last modified on July 14, 2023

Share this page

Facebook icon Twitter icon email icon

Print

print icon