Open wetneb opened 4 years ago
It may be a good idea to re-fetch the manifest in any case, in case the configuration changes or capabilities are added/removed.
It probably should be the case that updating the URL should only happen on user confirmation, since there may be situations where they're sending sensitive data to the endpoint and want control over any changes to it.
If a service changes its endpoint URL, but clients have already fetched its manifest at the old URL, they might keep sending queries via POST to the endpoint. Since there is no way to redirect POST requests in HTTP, those requests can potentially fail.
This situation is encountered by the Wikidata reconciliation service: the hosting infrastructure has decided to change URLs from
tools.wmflabs.org/*/
to*.toolforge.org/
, by putting HTTP redirects in place.One way to solve this would be to encourage clients to perform a GET request on the manifest URL before any "session" of using the endpoint, and follow any HTTP redirects to obtain the new URL for the reconciliation service.