...
An example of the DataWare import configuration will be given here. The importType is named DataWare which should be configured in the general section of the import. De URL to the rest service should be configured here as well. The actual data to be retrieved can be tuned by adding setting the relativeViewPeriod and the timeSeries to specify the locations and parameters. N.B.: the used parameters and locations have to be specified in the Parameters.xml and Locations.xml configmapped in .
TimeZone is assumed to be configured in the general section, otherwise GMT is assumed.
Code Block | ||||
---|---|---|---|---|
| ||||
<?xml version="1.0" encoding="UTF-8"?> <timeSeriesImportRun xmlns="http://www.wldelft.nl/fews" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.wldelft.nl/fews http://fews.wldelft.nl/schemas/version1.0/timeSeriesImportRun.xsd"> <import> <general> <importType>DataWare</importType> <serverUrl>http://server:port/rest/read/data/</serverUrl> <relativeViewPeriod unit="day" start="-1" end="0" startOverrulable="true" endOverrulable="true"/> <idMapId>IdImportDataWare</idMapId> <importTimeZone> <timeZoneName>GMT-5</timeZoneName> </importTimeZone> </general> <timeSeriesSet> <moduleInstanceId>ImportDataWare</moduleInstanceId> <valueType>scalar</valueType> <parameterId>19839<<parameterId>H.obs</parameterId> <locationId>1ha<<locationId>Amsterdam</locationId> <timeSeriesType>external historical</timeSeriesType> <timeStep unit="nonequidistant" /> <readWriteMode>add originals</readWriteMode> </timeSeriesSet> <timeSeriesSet> <moduleInstanceId>ImportDataWare</moduleInstanceId> <valueType>scalar</valueType> <parameterId>19840<<parameterId>H.obs</parameterId> <locationId>1ha<<locationId>Delft</locationId> <timeSeriesType>external historical</timeSeriesType> <timeStep unit="nonequidistant" /> <readWriteMode>add originals</readWriteMode> </timeSeriesSet> <timeSeriesSet> <moduleInstanceId>ImportDataWare</moduleInstanceId> <valueType>scalar</valueType> <parameterId>19839<<parameterId>Q.obs</parameterId> <locationId>2ha<<locationId>Amsterdam</locationId> <timeSeriesType>external historical</timeSeriesType> <timeStep unit="nonequidistant" /> <readWriteMode>add originals</readWriteMode> </timeSeriesSet> <timeSeriesSet> <moduleInstanceId>ImportDataWare</moduleInstanceId> <valueType>scalar</valueType> <parameterId>19840<<parameterId>Q.obs</parameterId> <locationId>2ha<<locationId>Delft</locationId> <timeSeriesType>external historical</timeSeriesType> <timeStep unit="nonequidistant" /> <readWriteMode>add originals</readWriteMode> </timeSeriesSet> </import> </timeSeriesImportRun> |
The previous timeseries will be mapped using theIdImportDataWare id mapping:
Code Block | ||||
---|---|---|---|---|
| ||||
<parameter external="19839" internal="H.obs" /> <parameter external="19840" internal="Q.obs" /> <location external="1ha" internal="Amsterdam" /> <location external="2ha" internal="Delft" /> |
The previous configuration will result in the following 4 REST urls being used:
...