FHIR icon indicating copy to clipboard operation
FHIR copied to clipboard

Refactor SingleResourceResult to avoid returning resource since it will never be updated by PL any more

Open punktilious opened this issue 2 years ago • 1 comments

Persistence methods no longer modify the resource (the resource must be fully formed before it hits the persistence layer. This means that there's no reason for the method to return the resource. Some refactor is warranted to clean up the interface.

QA NOTE: Audit should be double-checked after this change.

Also, while editing we should resolve the fact that success and interactionStatus overlap in meaning. The meaning and use of the success and interactionStatus fields in SingleResourceResult have some overlap.

Recommend we remove the success member, and replace the isSuccess implementation with something that interprets the value of interactionStatus.

Extend the use of interactionStatus to cover other possibilities, including something to represent a failed interaction.

punktilious avatar Oct 28 '21 15:10 punktilious

I believe Robin used the SingleResourceResult resource field to implement https://github.com/LinuxForHealth/FHIR/pull/3815 and so I'm not sure this one is possible any more (or at least may not be worth the effort). @punktilious what do you think?

lmsurpre avatar Aug 02 '22 18:08 lmsurpre