Open vincentsarago opened 1 year ago
Since the start of tifeature/timvt/tipg, we designed the application with having a list of the available collections/layers stored in the application State: https://github.com/developmentseed/tipg/blob/489f0243b0b4f0d46d12f06a1baf0bccc1d4232a/tipg/db.py#L83
State
This gave some advantages:
The collection_catalog is created at application startup https://github.com/developmentseed/tipg/blob/489f0243b0b4f0d46d12f06a1baf0bccc1d4232a/tipg/main.py#L65-L80 because we assumed it's a pretty costly process.
collection_catalog
The problem then (as explained in https://github.com/developmentseed/eoAPI/pull/55#issuecomment-1471006644) is when you have changed in the DB (e.g new table) it won't show up in the application because the catalog is now updated.
id
limit
offset
spatial_filter
temporal_filter
cc @bitner
We will also need to take into account merging in the overrides that can come from environment variables.
I will note, that we can use the existing function right now to filter by collection by setting tables= and functions=.
Since the start of tifeature/timvt/tipg, we designed the application with having a list of the available collections/layers stored in the application
State
: https://github.com/developmentseed/tipg/blob/489f0243b0b4f0d46d12f06a1baf0bccc1d4232a/tipg/db.py#L83This gave some advantages:
The
collection_catalog
is created at application startup https://github.com/developmentseed/tipg/blob/489f0243b0b4f0d46d12f06a1baf0bccc1d4232a/tipg/main.py#L65-L80 because we assumed it's a pretty costly process.The problem then (as explained in https://github.com/developmentseed/eoAPI/pull/55#issuecomment-1471006644) is when you have changed in the DB (e.g new table) it won't show up in the application because the catalog is now updated.
Proposal
collection_catalog
id
(to return only one collection),limit
,offset
,spatial_filter
andtemporal_filter
cc @bitner