Closed nmaytan closed 3 months ago
The concept of deleting detectors/instruments needs more attention, as removing a once-used instrument will mean that our tooling will "forget" it ever existed. This has some consequences; for one, we would not be able to sync/update the corresponding assets directory permissions if needed.
Probably we need an idea of "historical instruments" which are seen by our tooling and for which directories are updated if existing, but not created if non-existing.
We also need the capability to update/modify information for a given instrument, but this too requires some thought since this implies that the directory name could be changed and cause the same issues as above.
For now, I add only a simple deletion endpoint, so that we have a way to remove typos/mistakes and make changes by i.e. deleting and recreating the instrument.
I've switched from DELETE
to PUT
for inst/det deletion as, per RFC9110, a request body should not be sent with DELETE
requests.
Although request message framing is independent of the method used, content received in a DELETE request has no generally defined semantics, cannot alter the meaning or target of the request, and might lead some implementations to reject the request and close the connection because of its potential as a request smuggling attack [...]
This PR:
add_service
which crept in