Capability statement refreshes when profiles are updated#5330
Conversation
src/Microsoft.Health.Fhir.Shared.Core/Features/Validation/ProfileValidator.cs
Fixed
Show fixed
Hide fixed
src/Microsoft.Health.Fhir.Shared.Core/Features/Validation/ProfileValidator.cs
Show resolved
Hide resolved
src/Microsoft.Health.Fhir.Shared.Core/Features/Validation/ServerProvideProfileValidation.cs
Fixed
Show fixed
Hide fixed
src/Microsoft.Health.Fhir.Shared.Core/Features/Validation/ServerProvideProfileValidation.cs
Show resolved
Hide resolved
Writing tests to validate the logic of the background loop.
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
src/Microsoft.Health.Fhir.Core/Features/Conformance/CapabilityStatementBuilder.cs
Outdated
Show resolved
Hide resolved
src/Microsoft.Health.Fhir.Shared.Core/Features/Validation/ServerProvideProfileValidation.cs
Outdated
Show resolved
Hide resolved
Renamed sync method for profile sync.
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
🔍 AI Code Review SummaryPR: "Capability statement refreshes when profiles are updated" 🔴 CRITICAL ISSUES1. Race Condition in Sync Signaling MechanismThe Scenario:
Result: Server stuck on version B, missed version C until a NEW update (D) occurs. Recommendation: Use a version token/counter instead of boolean flag, or make 2. Thread Safety of Shared Fields
Recommendation: Use 3. Dispose Doesn't Await Background Task
Recommendation: Implement 🟡 MEDIUM ISSUES
🟢 NO ISSUES FOUND
📋 SUMMARY OF RECOMMENDATIONS
⚡ Performance NoteWith default settings (5 minute interval):
However, without config validation, a misconfigured low interval could cause significant database load. This review was generated by AI assistants analyzing the PR diff and source files. |
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Description
In this PR there are a few updates on the way how SystemConformanceProvider updates its profiles and on how ServerProvideProfileValidation works.
With these changes, Profile changes will not be reflected at the Capability Statement just once every 4hs, these updates will happen in less than 2 minutes. And all replicas of the services will be updated as well, minimizing the risk of having different replicas out of sync.
Changes:
Related issues
Addresses AB#179963.
Testing
FHIR Team Checklist
Semver Change (docs)
Patch|Skip|Feature|Breaking (reason)