470 likes | 630 Views
How to use the VM. Practical Guide Nele Smeets PASODOBLE Annual Meeting Helsinki 12-15 June, 2012. Goal. Create meta data for my service and insert the meta data in the central catalogue Publish daily WMS maps for my service Publish hourly time series as WFS layer for my service.
E N D
How to use the VM Practical Guide Nele Smeets PASODOBLE Annual Meeting Helsinki 12-15 June, 2012
Goal • Create meta data for my service and insert the meta data in the central catalogue • Publish daily WMS maps for my service • Publish hourly time series as WFS layer for my service
Step 1: Install the service integration tool • Virtual machine • Installation manual describes the installation and network configuration process • Configure the virtual machine: • Contact information used by GeoServer • URL of FTP site AEAT (catalogue) • Public URL for GeoServer • Result: (GENESIS) ARMS - data publication tool (GENESIS) Metadata editor (CC-QUALITY) Virtual Machine
Step 2: Create meta data template • Download example template • Use the meta data editor to fill in the template • Save the template using the correct name: • pasodoble_region_pollutant_indicator_unit • e.g. pasodoble_blackforest_no2_dailyMaximum_ugm3 • Creating a template is done once (once for each service) • Check: The template will be added to the list of templates
Download meta data template (home page -> meta-data template)
Step 3: Convert output to correct format • NetCDF, CF compliant • Contains daily concentrations for one or more forecast days • For one service: • data for different regions are in different files • data for different pollutants are in different files • data for different indicators are in different files • data for different units are in different files • Namingconvention: • region_pollutant_indicator_unit_date.nc • e.g. blackforest_no2_dailyMaximum_ugm3_20120418.nc • e.g. blackforest_o3_dailyMaximum_ugm3_20120418.nc • Conversion should be added to your forecast chain
Step 4: FTP of NetCDF file to Virtual Machine • Use the following FTP configuration: • host: the IP address of your VM • user: ftpuser • password: pasodoble • The files are processed automatically: • meta data is generated, based on the template, and on meta data in the NetCDF file • the meta data is sent to the catalogue • the data is published as a WMS layer • The FTP should be done daily, so it should be added as the last part of your forecast chain
Step 5: Create hourly time series (optional) • Select airbase stations for your region • http://converters.eionet.europa.eu/xmlfile/airbase-stations.xml • Use AirbaseStation WFS of DLR: server URL: wdc.dlr.de/cgi-bin/pasodoble_eea_aq WFS layer: AIRBASE_STATIONS
Example WFS request (airbaseobservations): • http://wdc.dlr.de/cgi-bin/pasodoble_eea_aq? • request=getfeature& • service=WFS& • version=1.0.0& • typename=AIRBASE_STATIONS& • filter= • <Filter> • <BBOX> • <PropertyName>Box</PropertyName> • <Box srsName='EPSG:4326'> • <coordinates>6.984,47.489 9.484,49.239</coordinates> • </Box> • </BBOX> • </Filter>
The result of the WFS request is a XML file containing airbase stations
Step 5: Create hourly time series (optional) • Select airbase stations foryourregion • http://converters.eionet.europa.eu/xmlfile/airbase-stations.xml • UseAirbaseStation WFS of DLR • Computehourly time series foreach station, foreachforecastday • Insert the time series in the POSTGIS database • Result: The time series are available as WFS layer (GENESIS) ARMS (GENESIS) Metadata editor (CC-QUALITY) Virtual Machine
Example WFS request (hourly time series of concentrations): • http://rma.vito.be/geo_pasodoble/wfs? • request=getfeature&service=WFS&version=1.0.0& • typename=pasodoble:pasodoble_timeseries& • filter=<Filter><And> • <PropertyIsBetween> • <PropertyName>timestamp</PropertyName> • <LowerBoundary><Function+name="dateParse"><Literal>yyyy-MM-dd'T'HH:mm:ss</Literal> • <Literal>2012-06-04T00:00:00</Literal></Function></LowerBoundary> • <UpperBoundary><Function+name="dateParse"><Literal>yyyy-MM-dd'T'HH:mm:ss</Literal> • <Literal>2012-06-11T23:00:00</Literal></Function></UpperBoundary> • </PropertyIsBetween> • <PropertyIsEqualTo><PropertyName>pollutant</PropertyName><Literal>no2</Literal></PropertyIsEqualTo> • <PropertyIsEqualTo><PropertyName>stationid</PropertyName><Literal>BETR701</Literal> • </PropertyIsEqualTo> • <PropertyIsEqualTo><PropertyName>region</PropertyName><Literal>ghent</Literal></PropertyIsEqualTo> • <PropertyIsEqualTo><PropertyName>day</PropertyName><Literal>0</Literal></PropertyIsEqualTo> • </And></Filter>
Step 6: How can I check if everything is ok? • The meta data shouldbeadded to the catalogue. Thiscanbecheckedbygoing to the catalogue: • http://www.myair-eu.org/geonetwork/ • Search foryour service • The data shouldbepublished as WMS layer • check whether the layer is added in GeoServer (via home page) • open GeoServer, Layer Preview • Check logs: via home page
GeoServer Layer Preview (notice the time parameter in the URL)
GeoServer Layer Preview (no data for the given time parameter)
Parameterised URL: • http://rma.vito.be/pasodoble/faces/index.jsp? • name=Black Forest NO2 (Daily Maximum)& • wmsUrl=pasodoblevm.rma.vito.be/geoserver/arms/wms& • wmsLayer=arms:pasodoble_blackforest_no2_dailyMaximum_ugm3_d0& • wmsVersion=1.1.0& • wfsUrl=pasodoblevm.rma.vito.be/geoserver/arms/wms& • startDate=2012-04-18& • endDate=2012-04-18& • bbox=6.98438,47.4896,9.48438,49.2396 • * empty end date ≈ ‘now’
When using the parameterised URL, the web application is initialized for your service
Whenusing the parameterised URL, the web application is initializedforyour service
Conclusion: overview of the steps Forecast chain
GeoServer: Layer preview Add time parameter to URL: &time=2012-04-18
GeoServer: Layer preview No data for April 20: &time=2012-04-20
VM (GENESIS) ARMS - data publication tool (GENESIS) Metadata editor (CC-QUALITY) Virtual Machine