Page 1 CSISS Center for Spatial Information Science and Systems CWIC Development Team Meeting, 2014 CWIC OpenSearch Design and Implementation Yuanzheng Shao, Lingjun Kang, Archie Warnock {yshao3, lkang3}@gmu.edu [email protected]CWIC Workshop, Jan 28-30, 2014 Greenbelt, MD
22
Embed
Page 1 CSISS Center for Spatial Information Science and Systems CWIC Development Team Meeting, 2014 CWIC OpenSearch Design and Implementation Yuanzheng.
Page 3 CSISS Center for Spatial Information Science and Systems OGC r8 –OGC OpenSearch Geo and Time Extensions –Latest version, to be approved. –Voting page (https://portal.opengeospatial.org/?m=projects&a=view&proj ect_id=82&tab=5) OpenSearch Draft 5 –http://www.opensearch.org/Specifications/OpenSearch/1.1/D raft_5 ATOM Syndication Format –http://tools.ietf.org/search/rfc4287 CWIC OpenSearch Design - Standards
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1
CSISS Center for Spatial Information Science and Systems
CSISS Center for Spatial Information Science and Systems
• Issue– How to generate the response without passing dataset
identifier?• Error output• General response (See http://cwicdev.wgiss.ceos.org/opensearch/datasets.atom?)
CWIC OpenSearch Design - OSDD
Page 7
CSISS Center for Spatial Information Science and Systems
• Dataset Identifier (Mandatory)– The dataset identifier (datasetId) parameter is used to
specify the dataset identifier which could be retrieved from IDN as DIF Entry ID. This parameter is a required parameter. The client can not specify more than one dataset in single request
• Error handling for non-exist Dataset Identifier– Set HTTP Status code to 400– Generate user-friendly exception message in <subtitle>– Send the response to client
CWIC OpenSearch Design – Request (datasetId)
Page 8
CSISS Center for Spatial Information Science and Systems
id Fixed value: http://cwic.wgiss.ceos.org/opensearch/granules.atom
link Provide the “self” link corresponding to the request
link Provide the “search” link corresponding to the OSDD request
opensearch:totalResults The number of search results available for the current search.
opensearch:startPage Replaced with the page number of the set of search results desired by the search client.
opensearch:itemsPerPage The number of search results returned per page.
opensearch:Query Defines a search query that can be performed by search clients.
Page 12
CSISS Center for Spatial Information Science and Systems
• <feed>/<entry> element
CWIC OpenSearch Design – ATOM Response
Element Value
title granule name
id Fixed URL prefix followed by granule identifier. For example: http://cwic.wgiss.ceos.org/opensearch/granules.atom?uid=NAVO-L2P-AVHRR19_L.20091128-AVHRR19_L-NAVO-L2P-SST_s2348_e2352-v01.nc.bz2
updated granule update time
author Fixed value for each data provider
georss:box bounding box of specific entry
dc:date temporal range of specific entry
summary a text construct that conveys a short summary, abstract, or excerpt of an entry.
link see next slide
Archie Warnock
Should this be of the form datasetID:granuleID to assure uniqueness?
Page 13
CSISS Center for Spatial Information Science and Systems
• <feed>/<entry>/<link> element
CWIC OpenSearch Design – ATOM Response
Type of link
Definition rel value mime-type
data link representing a data file or other science data resource;
enclosure application/x-netcdf, application/x-hdf, etc.
metadata file with (usually) structured information about corresponding data files
describedBy (ESIP)via (OGC)
text/xml
browser image of the data typically used for making data request decisions
icon image/jpeg, image/pngetc.
order granule ordering url enclosure text/html
Page 14
CSISS Center for Spatial Information Science and Systems
CSISS Center for Spatial Information Science and Systems
CWIC OpenSearch Design - Error Handling
Page 16
CSISS Center for Spatial Information Science and Systems
• CWIC OpenSearch uses the HTTP status codes for client (4xx) and server (5xx) errors.– Client-side issues
• 400 Bad Request: The request has an invalid syntax (i.e. badly formatted geometry)
• 413 Request Entity Too Large: The request originates too many returnable hits
– For server side errors• 500 Internal Server Error: Default code for the server side for an
execution error• 501 Not Implemented: When requesting an unimplemented feature
(e.g. relation operator not supported)• 503 Service Unavailable: When the search service is temporarily not
available (due to overload or other reasons)• 504 Gateway Timeout: When the search engine is a broker or
aggregator to other services that fail to produce a answer within a giving time frame
CWIC OpenSearch Design – Error Handling
Archie Warnock
This is a duplicate of the previous page
Page 17
CSISS Center for Spatial Information Science and Systems
• Zero-result handling– Zero-result is not an error! HTTP status code sets to 200– Response shall contain a valid ATOM response without
<entry> element– Specify human-readable message in <subtitle> element– Set the value of <opensearch:totalResults> element to 0– Set the value of <opensearch:startIndex> element to 0– Set the value of <opensearch:itemsPerPage> element to 0
CWIC OpenSearch Design – Error Handling
Page 18
CSISS Center for Spatial Information Science and Systems
• Zero-result sample response
CWIC OpenSearch Design – Error Handling
<?xml version="1.0" encoding="UTF-8"?><feed xmlns="http://www.w3.org/2005/Atom" xmlns:opensearch="http://a9.com/-/spec/opensearch/1.1/"> <title>CWIC OpenSearch Response</title> <subtitle>No results found for your specific dataset and query parameters</subtitle> <updated>2014-01-22T21:18:20Z</updated> <author> <name>CEOS WGISS Integrated Catalog (CWIC) - CWIC Contact - Web: http://wgiss.ceos.org/cwic</name> <email>[email protected]</email> </author> <id>http://cwicdev.wgiss.ceos.org/opensearch/granules.atom</id> <opensearch:totalResults>0</opensearch:totalResults> <opensearch:startPage>0</opensearch:startPage> <opensearch:itemsPerPage>0</opensearch:itemsPerPage></feed>
Page 19
CSISS Center for Spatial Information Science and Systems
CWIC OpenSearch Implementation
Page 20
CSISS Center for Spatial Information Science and Systems
• Existing catalog analysis– Provide OpenSearch API, like ECHO and CCMEO
• Solution: Reuse native OpenSearch API, and convert the response to universal CWIC OpenSearch response
– Provide CSW API, like GHRSST• Solution: Convert CWIC OpenSearch request to CSW request, interact
with remote CSW catalog, parse CSW response and convert it to universal CWIC OpenSearch response
– Provide SOAP API, like USGS/LSI• Solution: Convert CWIC OpenSearch request to SOAP request, interact
with SOAP API, parse SOAP response and convert it to universal CWIC OpenSearch response
– Provide HTTP GET, like INPE• Solution: Issue GET request, retrieve XML response, parse the XML
and convert to universal CWIC OpenSearch response
CWIC OpenSearch Implementation – Scenario
Page 21
CSISS Center for Spatial Information Science and Systems
• Supported catalogs– INPE– USGS/LSI– GHRSST
• Ongoing integrated catalogs– ECHO– CCMEO
• Demo– CWIC-Start
CWIC OpenSearch Implementation
Page 22
CSISS Center for Spatial Information Science and Systems