...
- dataSource=ORG: Original data
- dataSource=PRO: Product data
- dataSource=STATTideInsert5: Statistical data
Configuring the Import
...
Code Block | ||||
---|---|---|---|---|
| ||||
<?xml version="1.0" encoding="UTF-8"?> <moduleInstanceDescriptors 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/moduleInstanceDescriptors.xsd" version="1.0"> ... <moduleInstanceDescriptor id="ImportWiskiService"> <description>Imports WiskiService</description> <moduleId>TimeSeriesImportRun</moduleId> </moduleInstanceDescriptor> ... </moduleInstanceDescriptors> |
...
An example of the WiskiService import configuration is given here. The importType is named WiskiService which should be configured in the general section of the import. The URL to the rest service should be configured here as well. The actual data to be retrieved can be tuned by setting the relativeViewPeriod and the timeSeries to specify the locations and parameters. N.B.: the used parameters and locations have to be mapped with an idMap (IdWiskiService in this example).
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>WiskiService</importType> <serverUrl>http://180.166.177.90dummy_hostname:8090/PudongDEPdummy_servicename/</serverUrl> <user>anonymous<<user>dummy_username</user> <password>pdsw323006<<password>dummy_password</password> <relativeViewPeriod unit="week" start="-1" end="0" startOverrulable="true" endOverrulable="true"/> <idMapId>IdWiskiService</idMapId> <importTimeZone> <timeZoneName>GMT-5</timeZoneName> </importTimeZone> </general> <properties> <string key="dataSource" value="ORG"/> <!-- Supported dataSource values are: ORG = Original PRO = Product .... --> </properties> <timeSeriesSet> <moduleInstanceId>ImportWiskiService</moduleInstanceId> <valueType>scalar</valueType> <parameterId>H.obs</parameterId> <locationId>Amsterdam</locationId> <timeSeriesType>external historical</timeSeriesType> <timeStep unit="nonequidistant"/> <readWriteMode>add originals</readWriteMode> </timeSeriesSet> <timeSeriesSet> <moduleInstanceId>ImportWiskiService</moduleInstanceId> <valueType>scalar</valueType> <parameterId>H.obs</parameterId> <locationId>Delft</locationId> <timeSeriesType>external historical</timeSeriesType> <timeStep unit="nonequidistant"/> <readWriteMode>add originals</readWriteMode> </timeSeriesSet> <timeSeriesSet> <moduleInstanceId>ImportWiskiService</moduleInstanceId> <valueType>scalar</valueType> <parameterId>Q.obs</parameterId> <locationId>Amsterdam</locationId> <timeSeriesType>external historical</timeSeriesType> <timeStep unit="nonequidistant"/> <readWriteMode>add originals</readWriteMode> </timeSeriesSet> <timeSeriesSet> <moduleInstanceId>ImportWiskiService</moduleInstanceId> <valueType>scalar</valueType> <parameterId>Q.obs</parameterId> <locationId>Delft</locationId> <timeSeriesType>external historical</timeSeriesType> <timeStep unit="nonequidistant"/> <readWriteMode>add originals</readWriteMode> </timeSeriesSet> </import> </timeSeriesImportRun> |
...
Example XML response from WiskiService service
...
Code Block | ||||
---|---|---|---|---|
| ||||
...This XML file does not appear to have any style information associated with it. The document tree is shown below. <ns:getProductDataResponse xmlns:ns="http://webservice.dep.kisters.de" xmlns:ax25="http://bean.dep.kisters.de/xsd"> <ns:return xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="ax25:DataBean"> <ax25:avg>0.0</ax25:avg> <ax25:data>20140930170000,351.0</ax25:data> <ax25:data>20140930170500,348.0</ax25:data> <ax25:data>20140930171000,351.0</ax25:data>...<ax25:data>20141031174000,109.0</ax25:data> <ax25:data>20141031174500,125.0</ax25:data> <ax25:data>20141031175000,110.0</ax25:data> <ax25:data>20141031175500,97.0</ax25:data> <ax25:data>20141031180000,107.0</ax25:data> <ax25:max>0.0</ax25:max> <ax25:maxTime xsi:nil="true"/> <ax25:min>0.0</ax25:min> <ax25:minTime xsi:nil="true"/> <ax25:para>WindDirection</ax25:para> <ax25:para_cname>风向</ax25:para_cname> <ax25:src>WISKI6</ax25:src> <ax25:stcd>CFA600</ax25:stcd> <ax25:sum>0.0</ax25:sum> </ns:return> </ns:getProductDataResponse> |
...