fix: unblock subscriptions-smoke (S3 loader without R4; smoke ids via PUT) - #1418
Merged
Merged
Conversation
… the R4 feature reload_stored_cache_for_tenant built its SearchParameterLoader with FhirVersion::default(), which only exists when the R4 feature is enabled, so every hfs build without R4 (R4B-, R5-, R6-only and their combinations) failed to compile helios-persistence with the s3 feature on. Use FhirVersion::default_enabled(), the helper meant for code that must compile in any single-version build.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
…vive The external subscriptions smoke POSTed its topic, Subscriptions and Encounters with a client-chosen id and then asserted on that id in the delivered notifications. HFS assigns the id on POST, so the expected Encounter/<id> focus never appeared and every leg failed with "rest-hook event bundle missing expected focus". Create them with PUT <Type>/<id> (update-as-create), which keeps the chosen id.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Two independent problems kept
subscriptions-smoke.ymlfrom running at all; both predate #1342 and neither is backend-specific.1.
hfsdid not compile without the R4 feature whens3was onS3Backend::reload_stored_cache_for_tenant(crates/persistence/src/backends/s3/storage.rs:403) built itsSearchParameterLoaderwithFhirVersion::default(), which only exists when theR4feature is enabled:That failed 10 of the 16 build jobs (run 35516683520). Switched to
FhirVersion::default_enabled(), the helper intended for code that must compile in any single-version build. The companion validator error was fixed in #1375.2. The smoke script asserted on ids the server no longer keeps
crates/hfs/tests/subscriptions/run_external_subscriptions_smoke.shPOSTed its topic, Subscriptions and Encounters with a client-chosenid, then asserted that delivered notifications referenceEncounter/<that id>. HFS assigns the id on POST, so every leg failed withrest-hook event bundle missing expected focus(run 35629993565: the captured bundle carriedEncounter/01a0c55f-…, the script expectedEncounter/enc-rest-…). The nine create calls now usePUT <Type>/<id>(update-as-create), which keeps the chosen id.Test plan
cargo check -p helios-hfs --no-default-features --features "<V>,subscriptions,sqlite,elasticsearch,postgres,mongodb,s3"forR5,R4B,R6, andR4B,R6hfs, R4 (backport topic) and R5 (native SubscriptionTopic): rest-hook, websocket and messaging passEncounter/enc-email-…— the exact assertion that was failingsubscriptions-smoke.ymlon this branch (run 35644104645): green — all 168 smoke legs pass, including the first-ever run of thepostgres-elasticsearch/mongodb-elasticsearchlegs added in ci: add postgres-elasticsearch and mongodb-elasticsearch legs to backend matrices #1342. Two legs initially failed on GitHub's artifact service (403 Forbidden: Error from intermediaryonFinalizeArtifact/ListArtifacts, unrelated to storage behaviour); re-running just those two passed.