feat: DTOSS-10704 - Replace NEMS Subscriptions with new Caas based updates. Added ManageCaasSubscription function#1575
Merged
SamAinsworth-NHS merged 60 commits intomainfrom Sep 5, 2025
Conversation
…signature as ManageNemsSubscription.
…rvice and CheckSubscriptionStatus into ManageCaasSubscription
…lacement-mesh-branch
…-subscription-fixes
…num-to-nems-data-service-and-table
…gn with Required tags
…to ManageCaasSubscription
…l in MeshMailboxExtension
…n strings, retained 'isStubbed'
…rrected return type in SendSubscriptionRequest stub
…nt for ManageCaasSubscription
…anageCaasSubscription function
…s as no longer relevant, added asserts for exception handler logs.
…ect - adjusted unit tests to match.
|
alex-clayton-1
approved these changes
Sep 4, 2025
Warren-Pitterson
approved these changes
Sep 5, 2025
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.



Description
This branch introduces a new MESH-based CaaS subscription capability and shared MESH infrastructure, plus related infra/config updates and tests. The summary below reflects only changes unique to this branch compared with origin/main.
ManageCaasSubscriptionSubscribe,Unsubscribe(stub),CheckSubscriptionStatus,NemsSubscriptionDataService(pass-through), and a nightlyPollMeshMailboxtimer.nhs_number) via a new shared sender. In dev, a stubbed sender can be used viaIsStubbed.NEMS_SUBSCRIPTIONwithSubscriptionSource = MESH.Shared/Common:MeshMailboxExtension,MeshConfig/MailboxConfigto register the MESH client and mailboxes (supports Key Vault or local certs and server CA chain).IMeshSendCaasSubscribe+MeshSendCaasSubscribeandMeshSendCaasSubscribeStubfor local/dev.IMeshPoller+MeshPollerfor mailbox handshake validation.CertificateHelpermoved toShared/Common/Utilitiesand reused by MESH-enabled functions.SUBSCRIPTION_SOURCEtodbo.NEMS_SUBSCRIPTION; new enumSubscriptionSource { NEMS = 1, MESH = 2 }; EF model updated.SubscriptionSource = NEMS.NemsSubscriptionService/NemsMeshRetrievalandCaasIntegration/RetrieveMeshFileupdated to use the shared certificate parsing helper and cleaned imports.CurrentPostinglookup dependency from transform config/facade; updatedtransformRules.jsonto rely on PrimaryCareProvider/null checks and refined SMU/Welsh logic..env.examplegains optionalCAAS_SUBSCRIBE_TO_MAILBOX/CAAS_SUBSCRIBE_FROM_MAILBOXoverrides for the new function.compose.core.yamladds amanage-caas-subscriptionservice (disabled by default, with example env);compose.cohort-distribution.yamlremovesCurrentPostingUrl.ManageCaasSubscriptionfunction app (stubbed by default) and remove obsoleteCurrentPostingUrlwiring.stage-2-test.yamlensures artifact upload runs withif: always()and ignores missing files. This means if a test fails the report is still uploaded to aid investigation.MeshPoller,MeshSendCaasSubscribe, andManageCaasSubscription.Context
This work progresses the move toward a MESH-based CaaS subscription path, standardising MESH client setup via shared infrastructure, adding a nightly mailbox handshake to validate connectivity, and recording subscription source for observability. It also removes a transform-time dependency on reference data (CurrentPosting) in favour of rule changes and primary-care-provider checks.
DTOSS-10704
Type of changes
Checklist
Sensitive Information Declaration
To ensure the utmost confidentiality and protect your and others privacy, we kindly ask you to NOT including PII (Personal Identifiable Information) / PID (Personal Identifiable Data) or any other sensitive data in this PR (Pull Request) and the codebase changes. We will remove any PR that do contain any sensitive information. We really appreciate your cooperation in this matter.