-->

How to incorporate OperationOutcome in searchset r

2019-09-10 06:15发布

问题:

Is it appropriate to return an OperationOutcome for an entry when we are not able to fully populate the optional fields due to technical limitations rather than data availability? If so, how do we do that?

I read up the documentation on the usage of OperationOutcome, but I think what I understood was that OperationOutcome with search.mode = 'outcome' can only be used when there is search failure and instead of populating the entry with the requested resource you should have searchset with the entry of OperationOutcome resource with search.mode = 'outcome' in the response from the server. And OperationOutcome should state the reason of the failure.

In this case we do not have a complete search failure, but have a partial failure where we are not able to fully populate the optional fields due to technical limitations.

Thanks

回答1:

It's acceptable to include an OperationOutcome as one of the entries in a query response bundle along-side the entries containing results of executing the search.

Possible reasons for doing this is if a search is expected to be executed against multiple repositories but some of the repositories couldn't be reached. Another is where you may want to explicitly warn that the results have been filtered or partially suppressed for security/consent reasons (if you're in a situation where the user has the right to know that.)

Bundle.search.mode exists so you can easily differentiate what results are from your search as opposed to being warnings contained in an OperationOutcome.

(If you can point to wording that's confusing, feel free to submit a change request so we can make the spec clearer.)



标签: hl7-fhir