radiantearth / stac-spec

SpatioTemporal Asset Catalog specification - making geospatial assets openly searchable and crawlable
https://stacspec.org
Apache License 2.0
772 stars 176 forks source link

Restructuring the repository #205

Closed m-mohr closed 5 years ago

m-mohr commented 6 years ago

As the spec and repository grows, things get structured based on historical decisions and don't reflect the current state of the spec well enough. As discussed on Gitter, there are several things that - IMHO - need to be restructured / changed:

Root:

API spec:

Extensions:

I think all extensions should reside in a separate folder. They should consist of at least three files anyway, which is enough to get a separate folder to not clutter the extensions folder.

JSON/Item spec:

Static catalog / catalog spec:

Dataset Spec:

General:

There are probably things to be added, feel free to add them below.

matthewhanson commented 6 years ago

+1, all looks good to me. I don't have any additional things off-hand, but I think we should probably do such a reorg sooner rather than later.

cholmes commented 6 years ago

Just put this in a review comment on the relevant PR, but worth pulling up here:

I want to review the 'naming' a bit. I fully agree we need to shift the naming, but I'm not sure STAC Catalog and STAC API are the best names. I'm definitely cool to merge this though, as it's a ton of great improvements.

But the 'SpatioTemporal Asset Catalog Catalog Spec' is the expanded version of 'STAC Catalog Spec', which is a bit weird. Also I think this spec should also have the /stac OpenAPI definition in it. Hopefully it's not a huge pain to build from the fragments for a /stac endpoint in this folder. But I'd ideally like to explain what the core 'catalog' is, and then express it in both OpenAPI and JSON Schema versions. And explain the core concept of the catalog here, and explain it can be done with static files or a dynamic server.

Not super set on the exact dividing between folders, but I do think we should introduce 'catalogs' and then from there explain the different implementation options (static (on s3, etc with links) and dynamic (implemented with a server)).

m-mohr commented 6 years ago

Also mentioned by @cholmes in the mentioned PR (#202) for the static-catalog/README.md:

The core spec starts to get pretty long here, and this & the next section don't necessarily add a whole lot. We could follow the stac-item folder a bit more closely, with a -spec.md and a readme. The readme can contain more info like this and the next section, and the -spec.md can be the actual core spec, and we keep that nice and tight.

cholmes commented 5 years ago

Thinking about this more, I think I do like 'item-spec' and 'catalog-spec'. And then I think we should put the /stac openapi doc in the 'catalog-spec', and then rename 'api-spec' to 'search-spec'.

Then we can still talk about 'static catalogs', that are a special case of catalogs that are implemented on S3/GCS/file servers, etc. But it's more just a note on implementation at the end, and we can also note that dynamic servers can organize catalogs how they want, etc.

m-mohr commented 5 years ago

Not sure whether we should really separate the API. I think it is nice to have it in a single rendered API documentation. Gives a better overview - in my opinion. But maybe that splitting it can be compensated by a good and straightforward documentation?

cholmes commented 5 years ago

Yeah, I see the appeal of having API all in one place. But if /stac implements catalog spec then I think we should probably have that openapi document there? Like it feels weird to wait to put any api document up until we talk about 'search'.

Like if we didn't split it up then I think it'd make sense to have spec docs for item, catalog and search, and then a api folder that is the openapi versions of things. Search I guess would just be an overview. And maybe a json schema validator of the search response?

matthewhanson commented 5 years ago

@m-mohr is this issue still valid given that the PR is merged?

m-mohr commented 5 years ago

@matthewhanson Yes, there is a todo list in the first comment/entry, which has some points still open/unchecked.

matthewhanson commented 5 years ago

@m-mohr this is part of the 0.6.0-rc1 milestone, can it be closed?

cholmes commented 5 years ago

I'll open issues on the remaining todos, and close this one once I do.

cholmes commented 5 years ago

Closing this issue, as the remaining open todos are now their own issues in future milestones: #296 #297 and #298

Thanks for all your work on this @m-mohr!