opengeospatial / ogcapi-styles

A Web API that enables map servers, clients as well as visual style editors, to manage and fetch styles.
https://ogcapi.ogc.org/styles
Other
10 stars 5 forks source link

Possibility to attach /styles to other end-points such as /collections/{collectionId} #8

Closed jerstlouis closed 3 years ago

jerstlouis commented 3 years ago

As discussed at the March 25, 2021 Members Meeting SWG session:

We identified use cases for providing styles usable with a specific collection, such as:

It would also be good for servers to have the option to independently decide whether to support any of the following capabilities at either end-points, or both:

As discussed, users might only have the styles management option at the dataset level, while the styles available for individual collections are automatically updated by the server, e.g. filtering rules to the collection to which they apply.

Similarly, the styles management API might be at available at a "multi-datasets" end-point (e.g. a landing page of landing pages), while the individual dataset and collection might automatically populate available styles based on styles / data association.

Two mechanisms for that styles / data association were defined in previous initiatives, including:

However, any mechanism could be used for deciding how the styles offered are selected for individual datasets and collections (e.g. if not explicitly managed by the user at these levels), and none of this should impact the Styles API itself.

Example implementations of the collection-level Styles API, as well as associated maps and tiles sub-resources, have already been successfully deployed so far by both CubeWerx and Ecere:

CubeWerx

https://test.cubewerx.com/cubewerx/cubeserv/demo/ogcapi/Daraa/styles https://test.cubewerx.com/cubewerx/cubeserv/demo/ogcapi/Daraa/styles/Night https://test.cubewerx.com/cubewerx/cubeserv/demo/ogcapi/Daraa/styles/Night?f=sld11 https://test.cubewerx.com/cubewerx/cubeserv/demo/ogcapi/Daraa/styles/Night/map https://test.cubewerx.com/cubewerx/cubeserv/demo/ogcapi/Daraa/collections/AgricultureSrf/styles https://test.cubewerx.com/cubewerx/cubeserv/demo/ogcapi/Daraa/collections/AgricultureSrf/styles/Night https://test.cubewerx.com/cubewerx/cubeserv/demo/ogcapi/Daraa/collections/AgricultureSrf/styles/Night?f=sld11 https://test.cubewerx.com/cubewerx/cubeserv/demo/ogcapi/Daraa/collections/AgricultureSrf/styles/Night/map?height=1024 https://test.cubewerx.com/cubewerx/cubeserv/demo/ogcapi/Daraa/collections/AgricultureSrf/styles/Night/tiles https://test.cubewerx.com/cubewerx/cubeserv/demo/ogcapi/Daraa/collections/AgricultureSrf/styles/Night/map/tiles

Ecere

https://maps.ecere.com/ogcapi/collections/Daraa/styles https://maps.ecere.com/ogcapi/collections/Daraa/styles/night https://maps.ecere.com/ogcapi/collections/Daraa/styles/night?f=sld https://maps.ecere.com/ogcapi/collections/Daraa/styles/night?f=mbgl https://maps.ecere.com/ogcapi/collections/Daraa/styles/night?f=cmss https://maps.ecere.com/ogcapi/collections/Daraa/styles/night/map https://maps.ecere.com/ogcapi/collections/Daraa/styles/night/map/tiles https://maps.ecere.com/ogcapi/collections/Daraa/styles/night/tiles https://maps.ecere.com/ogcapi/collections/Daraa:AgricultureSrf/styles https://maps.ecere.com/ogcapi/collections/Daraa:AgricultureSrf/styles/night https://maps.ecere.com/ogcapi/collections/Daraa:AgricultureSrf/styles/night?f=sld https://maps.ecere.com/ogcapi/collections/Daraa:AgricultureSrf/styles/night?f=mbgl https://maps.ecere.com/ogcapi/collections/Daraa:AgricultureSrf/styles/night?f=cmss https://maps.ecere.com/ogcapi/collections/Daraa:AgricultureSrf/styles/night/tiles https://maps.ecere.com/ogcapi/collections/Daraa:AgricultureSrf/styles/night/map https://maps.ecere.com/ogcapi/collections/Daraa:AgricultureSrf/styles/night/map/tiles

The /collections/{collectionId}/styles end-point was the one implemented by Ecere in Testbed 15 - Open Portrayal Framework.

See also the "follow the link" OGC API map by @joanma747 for how this supports the Maps & Tiles use cases to retrieve maps & tiles for a specific style.

serich commented 3 years ago

The March 25 recording and chat log are in this meeting folder.

My stupid question: is the latest version of the draft spec settled (and making its way through the approval process)? Or still open for substantial modifications?

jerstlouis commented 3 years ago

Thanks @serich

I believe it is fairly early in the standardization process... I don't think it ever went through an OAB review. The specfications I think reflect mostly the work that was done in Testbed 15 - Open Portrayal Framework (http://docs.opengeospatial.org/per/19-010r2.html).

That being said, and the API being quite straightforward (basically as simple as .../styles/{styleId}), I don't expect very substantial changes.

cportele commented 3 years ago

@serich - As @jerstlouis has said, the Styles API has been tested quite a bit in the innovation program (testbed 15, vector tiles pilots), but we still have to build up more momentum in the standardization process. For most parts, the Styles API is straightforward and just follows the HTTP semantics. There are a few aspects that will need more discussion (style metadata) or that were a bit awkward (links between collections and styles) and that need to be addressed by the SWG. Regarding the last point, I think the proposal in this issue is a good step to make the API more intuitive / "natural".

serich commented 3 years ago

Thanks @cportele and @jerstlouis .

I think everyone else in the SWG is already aware of this, so I hope it doesn't drain too much energy to address it.

One of the risks that we might want to mitigate is that we settle on a spec that can be implemented by two different providers, each of which asserts conformance, but the two implementations don't interoperate (or one interoperates with a conformant 3rd-party client and the other doesn't).

The approaches to mitigating this risk might differ depending on which of the three approaches (from yesterday's meeting) is being assumed. Perhaps we could identify a set of "core" conformance criteria based on one of the definitions, and then two additional sets to accommodate the other two definitions. Then hopefully the path to building the compliance testing would be easier later. I guess the difficult problem would be to figure out which is most suitable as the core. (Or maybe all three would need to remain independent?)

Anyway, my selfish interest is to better understand them as we proceed through Testbed-17, where we're building at least three new API specs (Aviation, Geo Data Cubes, and Moving Features). The idea will be to try to bake the mitigation in at the foundational level.

Thanks.

P.S. I'm sure there's a much briefer expression for what's in my lengthy description above, but I can't think of what it is right now... "transportable endpoint compliance test design" seems too heavy.

jeffharrison commented 3 years ago

From 20 April 2021 Styles SWG Mtg:

Clemens takes action to ensure that, in addition to having Styles as a top level Resource, we can have -

1) Styles under Collections, and

2) Use Maps and Tiles as a sub Resource of Styles

3) Keep Styles Metadata and not remove it

(SWG will review Issues that are open and adjudicate)

SWG discussed and there was NOTUC

jeffharrison commented 3 years ago

SWG recommends closing this Issue. Addressed by Pull Request #10

Stylable Layer Set topic moved over to OGC NA.