Sortable fields
A new approach is included regarding custom mappings. With custom mappings if we include new field as keyword, sorting based on that specific field is necessary. Sortable fields are already defined in the database_logic. However, the number of fields are limited to four only. Adding new field into sortable fields can be considered from the environmental variables after custom mappings are applied.
Example: - COLLECTIONS_SORTABLE_FIELDS=id,extent.temporal.interval,temporal,title
Custom Mappings from Config File
A custom mappings json template similar to the default template can be stored in config folder. Users can easily edit and apply it from the environmental variables. The sample config json is important to highlight general structure of the mappings json. This is traceable and can be used as master template.
Example: - STAC_CUSTOM_MAPPINGS_PATH=/app/stac_fastapi/config/config_mappings.json
Alternatives I've considered
The above two features are demonstrated in a pull request here #577
Sortable fields
A new approach is included regarding custom mappings. With custom mappings if we include new field as keyword, sorting based on that specific field is necessary. Sortable fields are already defined in the database_logic. However, the number of fields are limited to four only. Adding new field into sortable fields can be considered from the environmental variables after custom mappings are applied.
Example: - COLLECTIONS_SORTABLE_FIELDS=id,extent.temporal.interval,temporal,title
Custom Mappings from Config File
A custom mappings json template similar to the default template can be stored in config folder. Users can easily edit and apply it from the environmental variables. The sample config json is important to highlight general structure of the mappings json. This is traceable and can be used as master template.
Example: - STAC_CUSTOM_MAPPINGS_PATH=/app/stac_fastapi/config/config_mappings.json
Alternatives I've considered
The above two features are demonstrated in a pull request here #577