-
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
Concurrency issue during apply FHIRPathPatchReplace #2510
Comments
HI @seltsamD We've discussed internally. The underlying visitor is not ThreadSafe. A reproducing test case would help, and we can determine if there is any update we can make from there, or recommendation on how to approach this case. Thank you Paul |
FHIRPathUtil was using a shared static FHIRPathEvaluator but this is not thread-safe. Now we construct a new evaluator for each request. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
FHIRPathUtil was using a shared static FHIRPathEvaluator but this is not thread-safe. Now we construct a new evaluator for each request. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
FHIRPathUtil was using a shared static FHIRPathEvaluator but this is not thread-safe. Now we construct a new evaluator for each request. Signed-off-by: Lee Surprenant <lmsurpre@us.ibm.com>
I didn't reproduce this exact issue, but I did find that our FHIRPathUtil class was using a shared a FHIRPathEvaluator where it shouldn't be. In my test, it manifested like this:
I added my unit test and the fix for this to #2514. |
HI @seltsamD this issue has an associated PR that should address this issue. We've tested it in our environments, and are closing the issue. Should this not be satisfactory please let us know, and we can work with you on resolving any remaining elements to your issue, thank you, Paul |
Describe the bug
Under concurrent request apply FHIRPathPatch (replace command) produce com.ibm.fhir.model.patch.exception.FHIRPatchException
Environment
IBM FHIR 4.4.0
To Reproduce
Steps to reproduce:
Generate concurrent requests (more than 50 requests per second)
1. Fill valid com.ibm.fhir.model.resource.Parameters resource.
2. Create FHIRPathPatch object
FHIRPathPatch patch = FHIRPathPatch.from(parameters);
3. Apply patch to any resource
patch.apply(...) method throw
Expected behavior
FHIRPathPatch.apply method doesn't throw FHIRPatchException under load.
The text was updated successfully, but these errors were encountered: