-
-
Notifications
You must be signed in to change notification settings - Fork 3
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
FHIRStore
actor isolation
#26
Conversation
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.
Awesome job @philippzagar ⚡️⚡️⚡️
Fyi, I left some suggestions. But these are more or less like nice-to-have ones.
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #26 +/- ##
==========================================
+ Coverage 33.50% 34.97% +1.48%
==========================================
Files 21 21
Lines 1466 1467 +1
==========================================
+ Hits 491 513 +22
+ Misses 975 954 -21
Continue to review full report in Codecov by Sentry.
|
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.
Had some comments regarding the concurrency design of the Storage
type. I'm definitely missing the bigger pictures of all the inner workings, so feel free to comment on my concerns.
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.
Had two final comments.
LGTM 🚀
# Write tests for `FHIRResource` and its extensions. ## ♻️ Current situation & Problem The `FHIRResource` class and its extensions currently have 0% test coverage. We should increase the code coverage as much as possible, to ensure long-term maintainability. ## ⚙️ Release Notes - This PR doesn't change any features. It adds tests for the `FHIRResource`, `FHIRResource+Search`, and `ResourceProxy+DisplayName`. - For the `FHIRResource+Category` tests, it's best to wait until PR #26 is merged into the main branch, avoiding any potential conflicts or inconsistencies. ## 📚 Documentation Comments are added throughout the code. ## ✅ Testing Aim for >90% code coverage, but >80% is acceptable in this case. ## 📝 Code of Conduct & Contributing Guidelines By submitting creating this pull request, you agree to follow our [Code of Conduct](https://github.com/StanfordSpezi/.github/blob/main/CODE_OF_CONDUCT.md) and [Contributing Guidelines](https://github.com/StanfordSpezi/.github/blob/main/CONTRIBUTING.md): - [x] I agree to follow the [Code of Conduct](https://github.com/StanfordSpezi/.github/blob/main/CODE_OF_CONDUCT.md) and [Contributing Guidelines](https://github.com/StanfordSpezi/.github/blob/main/CONTRIBUTING.md). --------- Co-authored-by: Philipp Zagar <[email protected]>
FHIRStore
actor isolation♻️ Current situation & Problem
As references in #25, the current
FHIRStore
implementation is not ideal as it still uses preconcurrency locking mechanisms. Therefore, theFHIRStore
should be reimplemented to use Swift's structured concurrency and isolation mechanisms.⚙️ Release Notes
FHIRStore
actor isolation with structured concurrency, not relying on locks anymore.FHIRResource
s are notSendable
anymore (underlying ModelsR4 class is notSendable
)📚 Documentation
Documented all isolation thoughts
✅ Testing
--
📝 Code of Conduct & Contributing Guidelines
By submitting creating this pull request, you agree to follow our Code of Conduct and Contributing Guidelines: