-
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
equivalency check when X-FHIR-UPDATE-IF-MODIFIED to true is not detecting that a field changed #2313
Comments
lmsurpre
added a commit
that referenced
this issue
May 4, 2021
Previously, we constructed the excludePaths on each leaf node, then checked whether the current path started with any of those values. This was faulty because the exclude path Resource.id accidentally resulted in us ignoring fields like Resource.identifier as well. Now we construct the excludePaths as a set during the initial doVisitStart and we don't need "startsWith" because we the visitor supports returning a boolean to control whether child paths should be visited or not. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
lmsurpre
added a commit
that referenced
this issue
May 4, 2021
Previously, we constructed the excludePaths on each leaf node, then checked whether the current path started with any of those values. This was faulty because the exclude path Resource.id accidentally resulted in us ignoring fields like Resource.identifier as well. Now we construct the excludePaths as a set during the initial doVisitStart and we don't need "startsWith" because we the visitor supports returning a boolean to control whether child paths should be visited or not. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
lmsurpre
added a commit
that referenced
this issue
May 4, 2021
Previously, we constructed the excludePaths on each leaf node, then checked whether the current path started with any of those values. This was faulty because the exclude path Resource.id accidentally resulted in us ignoring fields like Resource.identifier as well. Now we construct the excludePaths as a set during the initial doVisitStart and we don't need "startsWith" because we the visitor supports returning a boolean to control whether child paths should be visited or not. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
lmsurpre
added a commit
that referenced
this issue
May 4, 2021
Previously, we constructed the excludePaths on each leaf node, then checked whether the current path started with any of those values. This was faulty because the exclude path Resource.id accidentally resulted in us ignoring fields like Resource.identifier as well. Now we construct the excludePaths as a set during the initial doVisitStart and we don't need "startsWith" because we the visitor supports returning a boolean to control whether child paths should be visited or not. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
lmsurpre
added a commit
that referenced
this issue
May 10, 2021
…2314) * issue #2313 - refactor FingerprintVisitor to avoid startsWith checks Previously, we constructed the excludePaths on each leaf node, then checked whether the current path started with any of those values. This was faulty because the exclude path Resource.id accidentally resulted in us ignoring fields like Resource.identifier as well. Now we construct the excludePaths as a set during the initial doVisitStart and we don't need "startsWith" because we the visitor supports returning a boolean to control whether child paths should be visited or not. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
Fix looks good. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Working with conditional update functionality (issues 2263 and 2284). See Performance Guide section 5.2:
https://ibm.github.io/FHIR/guides/FHIRPerformanceGuide/#5-ingestion-scenarios
Using FHIR main branch.
To reproduce:
-Create a Patient (PUT with predefined resource.id)
-Set header X-FHIR-UPDATE-IF-MODIFIED to true
-Set header Prefer to return=OperationOutcome
-PUT the same patient again
-Confirm history stays at "1" and OperationOutcome returns the following:
"Update resource matches the existing resource; skipping the update"
-Modify a field within "identifier" in the Patient resource and PUT
-Again received history at "1" and OperationOutcome returns the following:
"Update resource matches the existing resource; skipping the update"
Expected the resource to be saved as version "2"
The text was updated successfully, but these errors were encountered: