Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Behaviour for use of composition uid's in POST requests needs clarification #70

Open
serefarikan opened this issue Aug 29, 2018 · 3 comments
Milestone

Comments

@serefarikan
Copy link
Contributor

Even though @wolandscat has pointed out that use of OBJECT_VERSION_IDs for COMPOSITION.uid values does not imply any versioning semantics as per the specifications, at least one vendor and probably more (according to slack comments) use meaningful uid values for COMPOSITIONs.

The discussion on slack did not produce an answer to the following question: "do we consider this non-standard, yet widely(?) applied practice for rest specifications".

If the answer to the above question is yes, then we need to clarify what the REST endpoint should do when

  • a system id that is different than the REST endpoint's is provided as in xyz::some_other_system::1
  • a version that is not equal to 1 as in xyz::rest_implementing_system::3
    Because in case of meaningful COMPOSION.uid s the above conditions imply imports rather than creating new compositions.

if the answer to the above question is no, there are still decisions to be made.

If the REST back end simply ignores the whole (OBJECT_VERSION_ID) uid or components of it, does this constitute a problem REST wise, since we're creating a resource that is different than the one provided (uid dropped)? If we're determining the identifier of the resource (via setting its uid), should not this be a PUT? RESTful design assumes POST will create the resource identifier as far as I remember

Also, @bjornna made a point regarding client side generation of UIDs which is required to commit a folder and compositions together where the folder has uids of compositions referenced. I am not sure if this is possible with the current REST api, but assuming this will be introduced later, this requirement conflicts with the behaviour in which server silently drops incoming uid values.

I tried to come up with a set of rules that satisfy all conditions above and failed, even when we assume uid has no versioning semantics. Suggestions are welcome.

@bostjanl bostjanl added this to the 1.1.0 milestone Nov 5, 2018
@bostjanl
Copy link
Contributor

bostjanl commented Nov 5, 2018

This is a question for spec not just the REST api.

@sebastian-iancu
Copy link
Member

This relates to https://openehr.atlassian.net/browse/SPECPR-322

@sebastian-iancu
Copy link
Member

on a duplicate issue, Thomas replied:

My view (and actually, the documentation's view) is that COMPOSITION.uid should just be a simple Guid, if it is populated. There are questions about whether, if it is not populated on the client side, whether the server should add a Guid, and also what should be in that field on a retrieve.
#71 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants