Repository navigation
Merge release-3.12.2 into release-3.13.0 (STOP-765, STOP-774) - #409
Conversation
(cherry picked from commit 3379e00)
fix: restore code lost when release 3.12.0 was merged to main
Bring main into release-3.12.2 (restores code lost in the 3.12.0 merge)
The changes-feed snapshot capped beneficiaries at 25 per page because each one used to cost several identity lookups and a FHIR call. Records are now built with one query per table for the whole page (WorklistPagePrefetch, health IDs read locally); the remaining per-beneficiary mapping and address lookups in getBeneficiaryRecordsByRegIds are batched too, with the old per-row queries as the fallback. Raise the cap to 100 so a new tablet needs a quarter of the pages for its first download. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…refers for (STOP-774) The tablet placed these orders with its own order/push right after saving the screening. When it could not reach the hub at that moment the order was marked FAILED on the tablet only and never retried, and the registrar has no access to the X-ray/TrueNat screens to retry it. - After a screening save commits, the hub creates XRAY_CHEST / MTB orders for today's referred screenings on a single background thread. - A sweep every 2 minutes (diagnostic.referral-sweep.tick-ms) covers referred screenings from today that still have no order. - Skips beneficiaries with an order of that type created today (any status, so a FAILED device push stays with the nurse's Retry) or an open/completed one. - Only on a camp hub (stoptb.van.id set); central never sends device orders. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…d (STOP-774) Each feed page now carries createsReferralOrders (true on a camp hub). The tablet stops placing screening referral orders itself only after it sees this flag, so a hub older than this release keeps getting the tablet's push and no referral is lost if the app is updated first. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…tion Feed beneficiary records were built from the newest mapping at each address. When two registrations share an address ID, that mapping could belong to the other registration, so the requested record was missing and the feed moved past it. The registration ID now travels with its address, the record is built from that registration's mapping, and the prefetch loads that mapping's rows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
fix(sync): faster changes-feed first download; camp hub creates referral orders (STOP-765, STOP-774)
Brings the 3.12.2 hotfixes forward (STOP-765 faster changes-feed first download, STOP-774 camp hub creates referral orders, feed beneficiary record fixes, code merge fix). Conflict: TBConfirmedCaseServiceImpl imports only. Kept 3.12.2's wildcard domain/repo imports plus java.time.ZoneId and java.util.*, which cover the explicit follow-up imports 3.13.0 added. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Caution Review failedThe pull request is closed. Walkthrough
Merge Risk:
|
|



Brings the
release-3.12.2hotfixes forward intorelease-3.13.0.Tickets
Commits from 3.12.2
d9ba0424fix(sync): build feed beneficiary pages in batches and send 100 per pagee1acf2b7fix(sync): use the newest mapping when batching beneficiary addresses514ce59ffix(stoptb): camp hub creates the X-ray / TrueNat orders a screening refers for (STOP-774)5572b225fix(sync): report hub-side referral order creation in the changes feed (STOP-774)fe316629fix(sync): build feed beneficiary records from the requested registration647c69edfix code merge issueConflict resolution
One conflict, imports only, in
TBConfirmedCaseServiceImpl.java: 3.13.0 added explicit follow-up imports, 3.12.2 switched to wildcarddomain.iemr.*/repo.iemr.*and addedjava.time.ZoneId/java.util.*. Kept the 3.12.2 imports, which cover the 3.13.0 ones (checked no simple-name clashes withjava.util).Tests
mvn compilepasses.StopTBSyncCoverageTest, which fails with the same table list onrelease-3.12.2alone (badge, notification,tb_referral_follow_up,tb_tpt_follow_up,user_fcm_tokensnot classified). Not introduced by this merge.🤖 Generated with Claude Code
Summary by CodeRabbit