-
Notifications
You must be signed in to change notification settings - Fork 157
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
Populate Bundle.entry.response.outcome with validation warnings #2281
Comments
lmsurpre
added a commit
that referenced
this issue
Apr 23, 2021
1. FHIRRestHelper.validateBundle now returns a sparse array (modeled as a map) of bundle response entries with warnings. It used to construct an entire response bundle. 2. FHIRRestHelper.processEntriesByMethod replaces FHIRRestHelper.processEntriesForMethod and iterates the request entries a single time, instead of once-per-method. 3. Entries are collected into an array instead of "modifying" the responseBundle with each one (which forced lots of needless copying since our model is now immutable). I also made significant formatting changes in FHIRRestHelper. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
lmsurpre
added a commit
that referenced
this issue
Apr 23, 2021
1. FHIRRestHelper.validateBundle now returns a sparse array (modeled as a map) of bundle response entries with warnings. It used to construct an entire response bundle. 2. FHIRRestHelper.processEntriesByMethod replaces FHIRRestHelper.processEntriesForMethod and iterates the request entries a single time, instead of once-per-method. 3. Entries are collected into an array instead of "modifying" the responseBundle with each one (which forced lots of needless copying since our model is now immutable). I also made significant formatting changes in FHIRRestHelper. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
lmsurpre
added a commit
that referenced
this issue
Apr 23, 2021
1. FHIRRestHelper.validateBundle now returns a sparse array (modeled as a map) of bundle response entries with warnings. It used to construct an entire response bundle. 2. FHIRRestHelper.processEntriesByMethod replaces FHIRRestHelper.processEntriesForMethod and iterates the request entries a single time, instead of once-per-method. 3. Entries are collected into an array instead of "modifying" the responseBundle with each one (which forced lots of needless copying since our model is now immutable). I also made significant formatting changes in FHIRRestHelper. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
lmsurpre
added a commit
that referenced
this issue
Apr 24, 2021
1. FHIRRestHelper.validateBundle now returns a sparse array (modeled as a map) of bundle response entries with warnings. It used to construct an entire response bundle. 2. FHIRRestHelper.processEntriesByMethod replaces FHIRRestHelper.processEntriesForMethod and iterates the request entries a single time, instead of once-per-method. 3. Entries are collected into an array instead of "modifying" the responseBundle with each one (which forced lots of needless copying since our model is now immutable). 4. Stop duplicating custom operation results in the `Bundle.entry.response.outcome` field of the response. We already copy the operation's result in the `Bundle.entry.resource` and that should be sufficient. I also made significant formatting changes in FHIRRestHelper. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Verified that this is now working as described for the different options listed. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is your feature request related to a problem? Please describe.
While reviewing our bundle processing code, I noticed that we pass validation warnings back through Bundle.entry.resource (at least in some cases).
This is the proper location for errors, but for warnings the spec defines a supplemental location:
Bundle.entry.response.outcome
From the spec:
Describe the solution you'd like
Lets start adding our validation outcomes to
Bundle.entry.response.outcome
.However, I still like having clients be able to control whether the resource content comes back in the Bundle.entry.resource or not, so I propose we do this:
Bundle.entry.response.outcome
with validation hints / warningsBundle.entry.resource
Bundle.entry.resource
Bundle.entry.resource
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Acceptance Criteria
Additional context
There is plenty of room for cleanup here as well.
The text was updated successfully, but these errors were encountered: