-
Notifications
You must be signed in to change notification settings - Fork 246
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
Add FhirEngine interface method 'withTransaction' #2535
base: master
Are you sure you want to change the base?
Conversation
To support performing FhirEngine actions as a single atomic transaction
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left some suggestions for the api.
13b83cb
to
bf90f8c
Compare
bf90f8c
to
72be126
Compare
fhirEngine.create(patient02, patient03) | ||
patient01.gender = Enumerations.AdministrativeGender.FEMALE | ||
fhirEngine.update(patient01) | ||
fhirEngine.delete<Patient>(patient01ID) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you make this more logical ? In the sense that it reflects why withTransaction is needed. Maybe something like what you are trying to do but were failing because of absence of withTransaction.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've updated the tests to use an appointment that gets fulfilled by an encounter (to represent a visit) and an observation (to represent result to visit)
to better reflect need for atomic transactions
IMPORTANT: All PRs must be linked to an issue (except for extremely trivial and straightforward changes).
Fixes #2531
Description
Support performing FhirEngine actions as a single atomic transaction
Alternative(s) considered
Have you considered any alternatives? And if so, why have you chosen the approach in this PR?
Type
Choose one: (Bug fix | Feature | Documentation | Testing | Code health | Builds | Releases | Other)
Screenshots (if applicable)
Checklist
./gradlew spotlessApply
and./gradlew spotlessCheck
to check my code follows the style guide of this project../gradlew check
and./gradlew connectedCheck
to test my changes locally.