The Common Alerting Protocol (CAP) import function (<importType>CapAlerts</importType> and <importType>CapAlert</importType>) import functions import time series with CAP messages. The Common Alerting Protocol (CAP) is a simple but general format for exchanging all-hazard emergency alerts and public warnings over all kinds of networks. Import of Common Alerting Protocol Version 1.2 is implemented, more information can be found at: http://docs.oasis-open.org/emergency/cap/v1.2/CAP-v1.2-os.html
There are two import types:
In general the CapAlers importType will be used in operational forecasting systems. This import type will import the Web feed with the links to the active CAP alert messages. A typical CAP web feed is an XML file with the following content (https://alerts.ncdr.nat.gov.tw/RssAtomFeed.ashx?AlertType=11)
The CapAlerts import function will import the <entry> elements and use the <link> element to find the active CAP messages.
The Delft FEWS import function for CAP web feeds looks as follows; the importType in the <general> section is CapAlerts. The <serverUrl> is required when using the importType; the other configurable elements will be covered in the CapAlert import below.
The Cap Alert messages can be imported from a server or from a local file. When downloaded from a server it is best to use the CapAlerts import as this import contains the links to the active CAP messages. For importing historic or already downloaded CAP messages the Capalert importType can be used. Importing CAP messages requires the following Delft-FEWS configuration files to be edited/added.
The CAP import module instance is a standard Delft-FEWS import configuration file; example provided below.
This example imports CAP messages from the \CAP import folder of a local file system. an example CAP file is presented below.
From this file the following elements will be imported by FEWS.
The import module instance has a <property> element that is used for the geocode valueName. The property key = geoCodeValueName and the property value the geocode provided in the CAP file. If a geocode valueName is different from the configured property the CAP values will not be imported. It is therefore important to first check the CAP messages to import and copy the geocode value to the Delft-FEWS import module instance property. The property is addded as sometimes new geocodes are used that require different location id mapping files. The property element allows for filtering the imported CAP messages on correct id mapping tables.
As indicated above the sverity will be imported from the CAP messages. this severity will be a string that needs to be converted to a value on importing. This value is the actual time series value that will be stored in the FEWS database. The parameter of the time series will require an enumeration to do this value conversion on importing. a typical CAP parameter enumeration is provided below.
When the imported CAP time series is presented in the time series display table, the value will be automatically converted to the enumerated label.
When importing data from an external system, location ID mapping is a standard import process. An example of an ID mapping configuration file is provided below.