openEHR / specifications-ITS-REST

openEHR REST API Specifications
https://specifications.openehr.org/releases/ITS-REST/latest
Apache License 2.0
18 stars 15 forks source link

{preceding_version_uid} as path or header parameter? #73

Closed jakesmolka closed 5 years ago

jakesmolka commented 6 years ago

Updating resources COMPOSITION and DIRECTORY are somewhat similar methods (in scope of this question), but providing {preceding_version_uid} is handled differently in each case.

Same is true for deletion too.

Why do these cases need different implementations of providing {preceding_version_uid}?

jakesmolka commented 6 years ago

Sorry, just found the reason: https://openehr.github.io/specifications-ITS/ehr.html#design-considerations-http-headers

But to understand it completely, I really would like to know why "This is only required by a small set of resources"? I could image that directory objects are way more likely to be target of multiple requests at the same time than a specific composition. That's not really a technical explanation though.

bostjanl commented 5 years ago

We will change the composition PUT to use versioned_object_uid as path parameter and If-Match header for preceding version_uid.