Skip to content

[Proposal] Remove Child links (collections) in Landing page #797

Closed
@vincentsarago

Description

@vincentsarago

By default we add all the collections links to the landing page, but when the catalog grows this might become useless or really slow (we have catalogs with > 100 collections).

# Add Collections links
collections = self.all_collections(request=kwargs["request"])
for collection in collections["collections"]:
landing_page["links"].append(
{
"rel": Relations.child.value,
"type": MimeTypes.json.value,
"title": collection.get("title") or collection.get("id"),
"href": urljoin(base_url, f"collections/{collection['id']}"),
}
)

Note: When using pgstac with the collection-search extension enabled, we now return a default of 10 collections (default limit in pgstac) so the landing page of stac-fastapi-pgstac will only return the first 10 collections links

@m-mohr not sure if stac-browser is using the landing page child links or directly the /collections link

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestquestionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions