Closed abarciauskas-bgse closed 6 months ago
@abarciauskas-bgse I think we might be able to start a bit simpler than this and then add deeper configuration as needed. As discussed in the Slack channel we can probably initially avoid using API interactions in favor of static config files and static STAC collection files to ease development friction. I think we can keep the tiler routing configuration directly in the collection mapping so I don't think we need a Catalog
type in this case. A simple config file with
{
"gpm-imerg": {
"collection": "http://somehost/gpm-imerg_collection.json",
"tiler": "http://titiler-cmr"
},
"hls-l30": {
"collection": "http://somehost/hls-l30_collection.json",
"tiler": "http://titiler-cmr"
},
"somezarr": {
"collection": "http://somehost/somezarr_collection.json",
"tiler": "http://titiler-xarray"
}
}
I'd prefer to have explicit configuration for tiler routing control rather than logic that needs to be embedded in the front end code.
In the case of a "zarr" that has pyramids stored in different archives, we should strive to include all pyramid groups in a single datatree
accessible entrypoint so that titiler-xarray
only needs to be able to open a datatree
and use the agreed upon zarr pyramid convention to determine which group to use at which z-level.
Are we trying to cover use case 4.a in this application? I don't see an immediate need for this but I might be missing something.
@sharkinsspatial that makes sense to me! Thanks for simplifying things. I also agree
In the case of a "zarr" that has pyramids stored in different archives, we should strive to include all pyramid groups in a single datatree accessible entrypoint so that titiler-xarray only needs to be able to open a datatree and use the agreed upon zarr pyramid convention to determine which group to use at which z-level.
closing as completed
Need
The UI application will need a way to route tile requests to the correct titiler instance for a given collection. At this time, we assume all collections will have a STAC endpoint. Ideally, we can determine what titiler instance to use based on the STAC endpoint, but this is limiting since we would have to pre-define which titiler instances the application would route requests to.
Being forward looking, we want to make it easy for other STAC systems to use this UI code, so the configuration and logic should allow for the addition of other STAC catalogue endpoints which, presumably, may be associated with their own dynamic tiler instance, which may or may not be titiler-pgstac.
Proposal
We define a schema for catalogues and collections which includes a few additional values to inform the application as to how to route requests.
Here is the proposed schema:
And here is an example:
There will also be 2 other titiler instances. At this time we only anticipate one of each, so they may be configured as environment variables:
The logic to determine which titiler endpoint to use will be as follows:
/items
endpoint will be required to determine which assets to send to the titiler instance. b. If the titiler IS a pgSTAC instance, then we can use the mosaic register endpoint with the search parameters, like in the current VEDA UI.@oliverroick @sharkinsspatial @vincentsarago let me know if 👆🏽 makes sense to you, or you have other ideas, I am open.