Skip to content
This repository was archived by the owner on Jan 10, 2022. It is now read-only.
This repository was archived by the owner on Jan 10, 2022. It is now read-only.

Add proper link management #115

@sophieherrmann

Description

@sophieherrmann

Currently hardly any service returns proper links in their responses though this is at least strongly recommanded by the API specification. This should be changed.

Currently there is a very basic LinkHandler in the data service - see links.py. Having on LinkHandler class per service could enable us to add proper and consistent links to all requests in a service. For this the LinkHandler class needs to store meaningful links related to its service.

Additionally it should be mentioned that the DNS_URL environment variable will be removed therefore it will not be possible to add the service_url / base_url in the way it is currently implemented. (The variable is removed as the exact same information needs to be provided in the openapi.yml file and is therefore redundant and error prone.)

A solution to this problem would be to add only the link suffix in the services and the base_url in the ResponseHandler (see response.py) running on the gateway - which has access to the openapi.yml file where the base_url is stored. Good ideas for implementation details are welcome! ;)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions