Demystifing OGC APIs with GeoServer: introduction and status of implementation
Join this presentation for an introduction to OGC API Features, Styles, Maps and Tiles (and more!), the state of their development, their extensions, as well as how well the GeoServer implementation is tracking them.
31st 2017 • Developed in the repo for a bunch of months • A bunch of events shaped it • Commits history in the WFS_FES repository: WFS3 Hackaton Testbed 14 Vector Tiles Pilot Testbed 15 API Hackaton
WFS3 • Discussion • Implementation of WFS3 prototypes in various languages • GeoServer implementation: • First exposure to WFS3 • Remote participation, implemented a WFS3 community module for GeoServer • https://github.com/geoserver/geoserver/tree/2.19.x/s rc/community/wfs3
to the Vector Tiles Pilot • Prototyped in the WFS3 community module two extensions • Deliver vector data as tiles (MapBox Vector Tiles) • Publis the style source for client to render maps client side (SLD, GeoCSS, Mapbox) SLD interpreted client side to render vector tiles
interoperability • Based on OpenAPI/RESTful concepts • Resource/representation • HTTP verbs • Small core, a basic service can be implemented in a matter of days • Extensions for every other functionality
others, in the various encodings: /collections /collections/{collectionId} Backlinks to self and alternative representations (different formats/encodings) Links to each collection in each of its formats { "href":"http://data.example.org/collections.json", "rel":"self", "type":"application/json", "title":"this document" }
draft stage and changing: • Released: ◦ OGC API - Features - Core (Sept 2019) ◦ OGC API - Features - Coordinate Reference Systems by Reference (Oct 2020)
/collection/{collectionId}/items (features) • /collection/{collectionId}/items/{itemId} • Only supported CRS are • CRS84 (WGS84 lon/lat) • CRS84h (WGS84 lon/lat/height) • Schema not required, features can be anything: • Simple • Complex • Heterogeneous • “describeBy” can link to schema (optional)
be a GeoJSON document, GML, anything • Filtering • bbox in CRS84 or CRS84h • datetime (instant or range of times) • extra parameters declared in the API document (only by equality, not supported by GS) …/collections/buildings/items? bbox=41,54,42,55 &datetime=2018-02-12T23%3A20%3A52Z &buildingState=good
present (like in WFS 1.x and 2.x) but can be high • Paging works through links, "prev" and "next" rel values • Links can be implemented the way you want • GeoServer uses offset as an extra paging parameter [ { "href":"http://example.org/collections/buildings/items.json?limit:50", "rel":"prev", "type":"application/geo+json" }, { "href":"http://example.org/collections/buildings/items.json?limit:50&offset:50", "rel":"self", "type":"application/geo+json" }, { "href":"http://example.org/collections/buildings/items.json?limit:50&offset:100", "rel":"next", "type":"application/geo+json" } ]
filtering • filter/filter-lang/filter-crs, multiple query languages supported • First draft used CQL (supported by GeoServer). Public feedback asked for changes. • Current draft developing CQL2 (similar, yet not same)
description • RangeType: data structure (bands and types) • RangeSet: the actual pixel values • Metadata: any other info about the coverage DomainSet + RangeType + RangeSet + Metadata = ----------- Coverage Coverage Implementation Schema (JSON encoding)
• Params: width, height, bbox, crs, …. • Unlike WMS GetMap, all params are optional → similar to the GeoServer WMS reflector .../ogc/maps/collections/topp:states/styles/population/map?f=image/png
GeoServer implementation not 100% up to date • Adds resources for tiles, tile matrix sets, eventually styles • Tiles can be “map” or “data” tiles (vector/raster tiles)
from single collection • /collections/{collectionId}/maps 🡪 rendered tiles from single map • /collections 🡪 raw tiles from multiple collections (list of collections as query param) • /map 🡪 tiles from multi-layer map (list of collections as query param) • /add/your/own/here 🡪 if it can be sliced, we'll tile it
style in various encodings (GeoServer can do CSS 🡪 SLD, MBStyle 🡪 SLD, YSLD 🡪🡪 SLD) A stylesheet can be marked as “native” SLD 1.0 core SLD 1.1 core YSLD extension MBStyles community GeoCSS extension SLD 1.0 inspired object model, with extensions
it yet, no love lost for metadata!) Access to style source, native (CSS) and converted (SLD) when possible List of layers involved in the style (could have many) and attributes used in each (style editor can use them to check compatibility with available data) The style identifier
• STAC API • DGGS/DAPA (Data Access and Processing API) • Images (mosaic management) • More APIs NOT supported by GeoServer yet: • Records (CSW) • Processes (WPS) • Routes (WPS specific for routing) • Environmental Data Retrieval