Page MenuHomeSoftware Heritage

Remove all API endpoints using an origin id.
ClosedPublic

Authored by vlorentz on Sep 6 2019, 4:44 PM.

Details

Summary

They were already deprecated.

This will allow simplifying code in swh.storage.

Diff Detail

Repository
rDWAPPS Web applications
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

anlambert added a subscriber: anlambert.

Looks good to me. Let's get rid of these endpoints using these origin ids.

This revision is now accepted and ready to land.Sep 9 2019, 10:54 AM

For your information, I extracted all requests to swh-web in production containing /origin/ in their urls for the last 1 year (using the following Python script P522): 141892 requests were found.

As the associated elasticsearch index does not handle regexp query properly, I filtered the urls based on origin ids using grep ($ cat swh-web-origin-requests | grep -E /origin/[0-9]+)

All requests using origin ids for the last 1 year (aka today minus 1 year range) can be found here: P523 (for a total of 852 requests)

Almost all found requests consists querying an internal browse endpoint that has been removed since (rDWAPPS4762da3d332114f97bbebd86941d43a236929537).
This endpoint was called when performing an origin search through the Web UI.

Otherwise, only 18 requests to Web API endpoints using origin ids have been issued.

So removing the endpoints using origin ids seems pretty safe, considering they are not really used.

This revision was landed with ongoing or failed builds.Sep 10 2019, 11:57 AM
This revision was automatically updated to reflect the committed changes.