// Include common libraries /* AWS Technologies vocabulary */ // Systems !constant AWS "AWS" !constant AWS.Description "Amazon Web Services" !constant AWS.Chime "Amazon Chime" !constant AWS.Chime.Description "Communications service that lets you meet, chat, and place business calls inside and outside your organization, all using a single application." !constant AWS.IAM "AWS IAM" !constant AWS.IAM.Description "Identity and Access Management" !constant AWS.STS "AWS STS" !constant AWS.STS.Description "Security Token Service" // AWS Technologies !constant AWS_SQS "AWS Simple Queue Service" !constant AWS_REDIS "AWS ElastiCache for Redis" !constant AWS_SM "AWS SecretsManager" !constant AWS_LAMBDA "AWS Lambda" !constant AWS_RDS "AWS RDS" !constant AWS_DYNAMODB "AWS DynamoDB" !constant AWS_S3 "AWS S3" !constant AWS_SF "AWS StepFunction" !constant AWS_SNS "AWS Simple Notificaction Service" !constant AWS_GLUE "AWS Glue" /* Common vocabulary constants */ !constant RDCS "RocheDiabetes Care Solutions" !constant PROFSOL "Professional Solutions" !constant PLATFORM "Plaform" !constant SL "Accu-Check Smartguide Predict" !constant SL_KEY "Accu-Check_Smartguide_Predict" /* Technologies vocabulary */ // Common technologies !constant TLS "TLS" !constant JDBC "JDBC" !constant JSP "JSP" !constant NODE "NodeJS" !constant SPRING_MVC "Spring MVC" !constant SPRING_BOOT "Spring Boot" !constant MSSQL_EE "SQL Server Enterprise Edition" !constant POSTGRESQL "PostgreSQL" !constant DOTNET ".NET" !constant MFC "MFC" !constant SWIFT "Swift" // Formats !constant ACSPIX "ACSPIX" !constant JSON "JSON" !constant ROCHE_JSON "RocheJSON" // Communication channels !constant HTTPS "HTTPS" !constant JSON_HTTPS "JSON/HTTPS" !constant ACSPIX_HTTPS "ACSPIX/HTTPS" !constant CDF_HTTPS "CDF/HTTPS" !constant WS "WebSocket" // Languages !constant JS "JavaScript" !constant TS "TypeScript" !constant REACT "React" !constant JAVA "Java" !constant MONO "Mono" !constant SCALA "Scala" /* Persons constants */ !constant ADMIN "Admin" !constant ADMIN.Description "Roche administrator, that manages onboardings and centers; is always considered an 'internal' user" !constant HCP "HCP" !constant HCP.Description "The health care professional is the medical practitioner treating the patient; is always considered an 'external' user" !constant HCP.Master "HCP Master" !constant HCP.Master.Description "The healthcare professional (Master - Owner of Healthcare Center); is always considered an 'external' user" !constant PWD "PwD" !constant PWD.Description "Patient with diabetes is the end user of the solution / system; is always considered an 'external' user" !constant DSS "DSS" !constant DSS.Description "Digital support service user is a special Roche internal user that has access to production environment and can perform various maintenance and corrective tasks" !constant DEVOPS "DevOps" !constant DEVOPS.Description "The DevOps user is an internal Roche user responsible for the operation and maintenance of the infrastructure" /* Professional solution (Professional ART) vocabulary system constants */ !constant RDCP "RocheDiabetes Care Platform (RDCP)" !constant SP2C "SmartPix2Cloud (SP2C)" !constant RDCP.HCP.Portal "RDCP.HCP.Portal" !constant RDCP.HCP.Portal.Description "Allows Healthcare Professional accessing their patients and their medical data." !constant RDCP.HCP.SelfReg "RDCP.HCP.Self-Registration" !constant RDCP.HCP.SelfReg.Description "Allows owners of HCC's to register their Healthcare Center to start managing their healthcare center and patients in RDCP." !constant RDCP.BackofficePortal "RDCP.BackofficePortal" !constant RDCP.BackofficePortal.Description "Allows Roche Admins onboarding processes for new healthcare centers and management of existing ones." !constant RDCP.UniversalDTC "RDCP.UniversalDTC" !constant RDCP.UniversalDTC.Description "Allows readout and upload of medical data from blood glucose devices, insulin pumps and CGMs into RDCP." !constant RDCP.Patient.Portal "RDCP.Patient.Portal" !constant RDCP.Patient.Portal.Description "Allows patients to visualize their medical data, personal information and access home delivery." !constant RDCP.Legacy "RDCP.Legacy" !constant RDCP.Legacy.Description "Collection of legacy Backend Services to support RDCP (including legacy monolithic app)." !constant RDCP.Permissions "RDCP.Permissions" !constant RDCP.Permissions.Description "Allows validation of permissions, modules and access to specific resources within RDCP." !constant RDCP.Notifications "RDCP.Notifications" !constant RDCP.Notifications.Description "Allows management of Notifications." !constant RDCP.StripsManagement "RDCP.StripsManagement" !constant RDCP.StripsManagement.Description "Allows strips management (stock, delivery)." !constant RDCP.Patterns.And.Indicators "RDCP.Patterns.And.Indicators" !constant RDCP.Patterns.And.Indicators.Description "Allows enrichment patient's status based on predefined set of patterns." !constant RDCP.UserManagement.And.Records "RDCP.UserManagement.And.Records" !constant RDCP.UserManagement.And.Records.Description "Allows centralized access and management of RDCP users." !constant RDCP.Diagnostics.And.Medications "RDCP.Diagnostics.And.Medications" !constant RDCP.Diagnostics.And.Medications.Description "Diagnostics and Medications." !constant RDCP.UniversalDTC.Services "RDCP.UniversalDTC.Services" !constant RDCP.UniversalDTC.Services.Description "Allows additional support of various functionalities of uDTC (whitelisting of devices and their versions that are supported by RDCP)." !constant RDCP.Organizations "RDCP.Organizations" !constant RDCP.Organizations.Description "Provides APIs for management of organizations" !constant RDCP.Analytics "RDCP.Analytics" !constant RDCP.Analytics.Description "Allow recollection of metrics for analytics" !constant RDCP.Devices "RDCP.Devices" !constant RDCP.Devices.Description "Management of devices." !constant RDCP.VisitManagement.And.Communication "RDCP.VisitManagement.And.Communication" !constant RDCP.VisitManagement.And.Communication.Description "Allows managements of patients visits to the HCP's, recording of notes and communication between PwD's and HCP's." !constant Professional.RDCPReport "Profesional.RDCPReport" !constant Professional.RDCPReport.Description "Allows generation of reports using inbuilt or custom templates." /* Plaform ART vocabulary system constants */ !constant Platform.ApiManager "Platform.ApiManager" !constant Platform.ApiManager.Description "The Roche ecosystem API Gateway used to NAT all the traffic to / from each solution and service" !constant Platform.CIAMCM "Platform.CIAMCM" !constant Platform.CIAMCM.Description "Customer Identity and Access Management and Consent Management is the central storage for identity and consents of each user" !constant Platform.CIAMCM.Gigya "Platform.CIAMCM.Gigya" !constant Platform.CIAMCM.Gigya.Description "CIAMCM's Gigya instance for user identity management" !constant Platform.DiagnosticsAndMedications "Platform.DiagnosticsAndMedications (FHIRStack)" !constant Platform.DiagnosticsAndMedications.Description "Allows storage and retrieval of diagnostics and medications data of the patients." !constant Platform.DataIntegrations "Platform.DataIngetrations" !constant Platform.DataIntegrations.Description "Data integrations layer" !constant Platform.BDA "Platform.BDA" !constant Platform.BDA.Description "Big Data Analytics - RDC Data Lake for Clinical studies and commercial data" !constant Platform.PushNotifications "Platform.PushNotifications" !constant Platform.PushNotifications.Description "Service for sending push notifications to mobile devices" !constant Platform.LegalArchive "Platform.LegalArchive" !constant Platform.LegalArchive.Description "Service responsible for ensuring backup based on legal requirments" /* Personal solutions vocabulary system constants */ !constant Personal.mySugr "Personal.mySugr" !constant Personal.mySugr.Description "Software system comprised of mobile application (FE) used by PwD and back-end for managing diabetes" !constant Personal.Confidence "Personal.Smartguide" !constant Personal.Confidence.Description "Mobile application to manage and view Roche CGM sensor and send data to RDCS Platform" !constant Personal.Glucolytics "Personal.Predict" !constant Personal.Glucolytics.Description "Software system comprised of mobile application (FE) used by PwD and back-end for A.I. based predictions using the CGM and other relevant data" // Define workspace workspace "${RDCS} - ${SL}" "${RDCS} - ${Personal.Glucolytics}" { /* Load the Architectural Decision Records of the project. These can be one or multiple files (each decision should have an independent record). File naming convention -title_word_1-title_word_n.md (number should be 0001 .. 0100 .. 0954 ..). NOTE: file format is Markdown */ !adrs adrs /* Load the documentation associated with the project / solution. Basically the documentation_sad should contain all the chapters, in order, that composes the full SAD with reference to the diagrams as well. File naming convention -title_word_1-title_word_n.adoc (number should be 0001 .. 0100 .. 0954 ..). NOTE: file format is AsciiDoc */ !docs documentation_sad !identifiers hierarchical model { /* model properties - recommended setting the group separator so nested groups can be defined */ properties { "structurizr.groupSeparator" "/" } /* TODO: add the description of the solution TODO: CGM integrator calls Predic.DevieManagement to store device data + DeviceManagement talks to SL_DB Predict.BGM does not write/read to/from cache (REDIS) but directly to SL_DB CombinedObservations talkd to (data services): Insulin, Meals, Notes, BGM - and used by FE (mobile app) - ADD NOTES ATD: 409 - why "conflict" for devicepairing when the resource exists, it should be 200/204 INFO: FE takes data, through API call, from CIAMCM: Name, surname, email, registration country, IdentityID (used for consent management), FHIRID Profile data service: diabetes_type, push notification settings, target ranges, units (TBC Nada) */ /* Here we describe a few typical 'external' actors for the solution / system. These are persons and they can be useful for the solution or not, depending on the purpose (service used by other solutions / apps / backends) Other types of users can be defined, these are the typical ones only */ Pwd = person "PwD" "Patient with diabetes is the end user of the solution / system; is always considered an 'external' user" { tags "RocheExtPerson" perspectives { Security "PwD is the owner of the data and has the right to access, modify and delete it" } } hcp = person "HCP" "The health care professional is the medical practitioner treating the patient; is always considered an 'external' user" { tags "RocheExtPerson" } hcc = element "HCC" "Health Care Center" { tags "RocheHCC" } /* Here we describe a few typical 'internal' actors for the solution / system. These are persons and they can be useful for the solution or not, depending on the purpose (service used by other solutions / apps / backends) Other types of users can be defined, these are the typical ones only */ dss = person "DSS" "Digital support service user is a special Roche internal user that has access to production environment and can perform various maintenance and corrective tasks" { tags "Internal" } devops = person "DevOps" "The DevOps user is an internal Roche user responsible for the operation and maintenance of the infrastructure" { tags "Internal" } complaint_inv = person "Complaint Investigatior" "The Complaint Investigation user is an internal Roche user responsible for the investigation of complaints" { tags "Internal" } /* Here are described some generic software systems in the Roche ecosystem These are not exhaustive, just a few general ones used by all the solutions The solution specifics and it's dependencies have to be added below The systems below as well as the solution specific ones must follow the naming conventions of the Roche Architectural Standard as defined here https://confluence.rochedc.accentureanalytics.com/pages/viewpage.action?pageId=148046784 */ complaint_tool = softwareSystem "RDC Complaint Handling Tool" "The Roche Complaint handling tool set used by various levels of support, like Morpheus or SalesForce" { properties { } perspectives { } tags "RocheExt" } logs = softwareSystem "Infra.LogManagement" "The Roche Observability tool used by all components" { properties { "Tool" "DataDog" "Ownership" "DevOps" } perspectives { Security "Observability tool collecting logs, traces and metrics from all components" } tags "RocheExt" } secrets = softwareSystem "Infra.SecretsManagement" "The Roche Secrets Management tool used by all components" { properties { "Tool" "AWS Secrets Manager" "Ownership" "DevOps" } perspectives { Security "Secrets management tool used to store and retrieve secrets" } tags "RocheExt" } apiGW = softwareSystem "${Platform.ApiManager}" "${Platform.ApiManager.Description}" { properties { "ART" "Platform" "Ownership" "API Manager" } perspectives { Security "API Manager is the entry point for all the requests to the system; verify the identity of the caller and the validity of the request" } tags "RocheGateway" } /* Roche manufactures devices that interact with the software systems and are an integral part of the systems */ group "Devices" { cgm = element "CGM Patch" "Roche CGM Path" { properties { "ART" "CGM ART" } perspectives { Security "CGM Patch is worn by the PwD" } } } group "${PLATFORM}" { ciam = softwareSystem "${Platform.CIAMCM}" "${Platform.CIAMCM.Description}"{ properties { "ART" "Platform" "Ownership" "CIAMCM" } perspectives { Security "CIAMCM is the identity provider for all the Roche solutions" } tags "RocheExt" } fhir_stack = softwareSystem "${Platform.DiagnosticsAndMedications}" "${Platform.DiagnosticsAndMedications.Description}" { properties { "ART" "Platform" "Ownership" "FHIR Stack" } perspectives { Security "FHIR Stack is the clinical data repository for CGM, Meal, Insulin and Notes data" } tags "RocheExt" } app_sett = softwareSystem "Application Settings" "Store, retrieve and share settings for mobile apps" { properties { "ART" "Platform" "Ownership" "Common Services" } perspectives { Security "Application Settings is the service used to store and retrieve settings for mobile apps" } tags "RocheExt" } complaint_service = softwareSystem "Platform.ComplaintInvestigation" "Retrieves data from various solutions (data domains), aggregate them and return them as a response to complaint handling requests" { properties { "ART" "Platform" "Ownership" "Common Services" } perspectives { Security "Exposes endpoints for mobile apps to push data to; Pushes data to subscribed endpoints; Returns data as response to authorized requests" } tags "RocheExt" } bda = softwareSystem "${Platform.BDA}" "${Platform.BDA.Description}" { properties { "ART" "Platform" "Ownership" "BDA" } perspectives { Security "BDA is the service used to store analytics data" } tags "RocheExt" } push_notif = softwareSystem "${Platform.PushNotifications}" "${Platform.PushNotifications.Description}" { properties { "ART" "Platform" "Ownership" "Common Services" } perspectives { Security "Push Notifications is the service used to send push notifications to mobile apps" } tags "RocheExt" } legal_archive = softwareSystem "${Platform.LegalArchive}" "${Platform.LegalArchive.Description}" { properties { "ART" "Platform" "Ownership" "Common Services" } perspectives { Security "Legal Archive is the service used to store user data for legal purposes" } tags "RocheExt" } /* infastructure components in Platform that are used by multiple clients and services */ account_deletion_sns = element "PlatformAccountDeletion.SNS" "SNS topic used to notify the system about account deletion" "SNS" { tags "sns" } ciamcm_common_sns = element "CIAMCM.Common.SNS" "SNS topic used to notify the system about user data changes and clinical study actions" "SNS" { tags "sns" } ciamcm_clinicalstudydeletion_sns = element "CIAMCM.ClinicalStudyDeletion.SNS" "SNS topic used to notify the system about clinical study deletion" "SNS" { tags "sns" } } group "${PROFSOL}" { rdcp_report = softwareSystem "${Professional.RDCPReport}" "${Professional.RDCPReport.Description}" { properties { "ART" "Professional" "Ownership" "Team Of Thrones" } perspectives { Security "RDCP Report is the service used to generate and server reports for the PwD" } tags "RocheExt" } } group "${RDCS} - ${SL}" { sl_be = softwareSystem "${Personal.Glucolytics}.Backend" "${Personal.Glucolytics.Description}" { // data services data_cgm = container "Predict.CGM" "Data service responsible for storing and retrieving CGM data to/from the system" "NodeJS" { tags "nodejs" "interface" perspectives { Security "CGM data is read from FHIR Stack" } } data_insulin = container "Predict.Insulin" "Data service responsible for storing and retrieving Insulin data to/from the system" "NodeJS" { tags "nodejs" "interface" perspectives { Security "Insulin data is read from FHIR Stack" } } data_meal = container "Predict.Meal" "Data service responsible for storing and retrieving Meal data to/from the system" "NodeJS" { tags "nodejs" "interface" perspectives { Security "Meal data is read from FHIR Stack" } } data_profile = container "Predict.Profile" "Data service responsible for storing and retrieving User Profile data to/from the system" "NodeJS" { tags "nodejs" "interface" perspectives { Security "User Profile data is read from mobile app and Platform.AppSettings" } } data_bgm = container "Predict.BGM" "Data service responsible storing and retrieving BGM data to/from the system" "NodeJS" { tags "nodejs" "interface" perspectives { Security "BGM data is read from FHIR Stack" } } data_notes = container "Predict.Notes" "Data service responsible storing and retrieving notes data to/from the system" "NodeJS" { tags "nodejs" "interface" perspectives { Security "Notes data is read from FHIR Stack" } } cgm_integrator = container "Predict.CGMIntegrator" "Responsible for processing notifications from Platform services and retrieving the respective data" "NodeJS" { tags "nodejs" "interface" } data_combined = container "Predict.CombinedObservations" "Aggregator data service to retrieve BGM, meal, insulin, notes" "NodeJS" { tags "nodejs" "interface" perspectives { Security "BGM, meal, insulin, notes data is read from the data services and returned to the mobile app" } } device_management = container "Predict.DeviceManagement" "Service initializing the data gathering from Platform to execute the predictions" "NodeJS" { tags "nodejs" "interface" perspectives { Security "Initiate's the data gathering from Platform" } } // queues and topics data_notification = container "Prdict.DataNotifications.SQS" "Queue subscribed to diferrent SNS topics from ${PLATFORM} to receive notifications" "SQS" { tags "sqs" } cgm_integrator_sqs = container "Predict.CGMIntegrator.SQS" "Queue used to store pairing requests" "NOT USED / SQS" { tags "sqs" "not-used" } cs_datadeletion_sqs = container "Predict.ClinicalStudyDataDeletion.SQS" "Queue used to store clinical study deletion notifications" "SQS" { tags "sqs" } algo_trigger = container "Predict.AlgoTrigger.SNS" "SNS topic that fan's out new data available messages to worker services" "SNS" { tags "sns" } algo_trigger_pd = container "Predict.AlgoTriggerPD.SQS" "Queue to receive trigger notifications to start the Pattern Detection algorithm" "SQS" { tags "sqs" } algo_trigger_gp = container "Predict.AlgoTriggerGP.SQS" "Queue to receive trigger notifications to start the General Prediction algorithm" "SQS" { tags "sqs" } handler_notification_sqs = container "Predict.NotificationHandler.SQS" "Queue to exchange async messages about triggers of push notifications to the user" "SQS" { tags "sqs" "" } // data storage sl_db = container "Predict.RDS" "AWS RDS database that stores clinical data for predictions and user preferences" "PostgreSQL" { tags "rds" perspectives { Security "Clinical and patient profile data is stored in RDS" } } sl_cache = container "Predict.Cache" "AWS ElastiCache that acts as a temporary storage for clinical data" "Redis" { tags "es" perspectives { Security "CGM, Meal, Insulin, Notes and pattern data data is cached in Redis" } } // worker services worker_pd = container "Predict.PDWorker" "Worker service that executes the Pattern Detection wrapper" "NodeJS" { tags "nodejs" } worker_gp = container "Predict.GPWorker" "Worker service that executes the General Prediction wrapper" "NodeJS" { tags "nodejs" } data_pattern = container "Predict.PatternData" "Data service responsible for retrieving data used by pattern detection from the storage" "NodeJS" { tags "nodejs" "interface" } // wrapper services wrapper_pd = container "Predict.PDWrapper" "Wrapper service that executes the Pattern Detection algorithm" "NodeJS" { tags "nodejs" "interface" "wrapper" perspectives { Security "Pattern Detection algorithm data is retrieved from" } } wrapper_gp = container "Predict.GPWrapper" "Wrapper service that executes the General Prediction algorithm" "NodeJS" { tags "nodejs" "interface" "wrapper" perspectives { Security "General Prediction algorithm data is retrieved from" } } wrapper_short_hypo = container "Predict.ShortTermHypoWrapper" "Wrapper service that executes the Short Term Hypo algorithm" "NodeJS" { tags "nodejs" "interface" "wrapper" perspectives { Security "Short Term Hypo algorithm data is sent from" } } wrapper_sg = container "Predict.SGWrapper" "Wrapper service that executes the Sleep Genius algorithm" "NodeJS" { tags "nodejs" "interface" "wrapper" perspectives { Security "Sleep Genius algorithm data is sent from" } } analytics_algo = container "Predict.AnalyticsAlgo" "Service that sends analytics outputs to Platform.BDA using AWS kinesis firehose" "NodeJS" { tags "nodejs" "" } analytics_algo_kinesis = container "Predict.AnalyticsAlgo.Kinesis" "Kinesis firehose used to send analytics outputs to Platform.BDA" "Kinesis Data Stream" { tags "kinesis_stream" "" } //other services and functions account_deletion_lambda = container "Predict.AccountDeletion.Lambda" "Lambda function that deletes all user data from ${Personal.Glucolytics} when the user deletes his account" "Lambda" { tags "lambda" "" } handler_notification = container "Predict.HandlerNotification" "Service that handles notifications and forwards them to ${PLATFORM} to be sent to ${Personal.Glucolytics} mobile app" "NodeJS" { tags "nodejs" "" } //// report generation containers report_generation = container "Predict.ReportGeneration" "Service that generates reports for the PwD" "NodeJS" { tags "nodejs" "" } report_generation_queue = container "Predict.ReportGeneration.SQS" "Queue to receive report generation requests" "SQS" { tags "sqs" "" } report_request_forwarder = container "Predict.ReportRequestForwarder" "Service that forwards report requests to ${PROFSOL} ${Professional.RDCPReport}" "NodeJS" { tags "nodejs" "" } report_templates = container "Predict.ReportTemplates" "Bucket that stores report templates" "S3" { tags "s3" "interface" } // algorithm services group "${SL} Prediction Algorithm Services" { algo_pd = container "Predict.Algo.PatterDetection" ".." "Python" { tags "python" } algo_gp = container "Predict.Algo.GeneralPrediction" ".." "Python" { tags "python" } algo_short_hypo = container "Predict.Algo.ShortTermHypo" ".." "Python" { tags "python" } algo_sg = container "Predict.Algo.SleepGenius" ".." "Python" { tags "python" } cgm_event_detect = container "Predict.Algo.CGMEventDetect" ".." "Python" { tags "python" } feature = container "Predict.Algo.Feature" ".." "Python" { tags "python" } } app_archival_lambda = container "Predict.AppArchival.Lambda" ".." "Lambda" { tags "lambda" "not-used" } ciam_triage_notify = container "Predict.TriageNotify" "Lambda function to process SQS messages and trigger a step function under certain conditions" "Lambda" { tags "lambda" "not-used" } } } sl_fe = element "${SL}.Frontend" "Client mobile application (iOS & Android)" { tags "RocheMob" "ios_android" "Internal" perspectives { Security "The mobile app is used by the PwD to view his/her predictions and CGM data" } } confidence = element "Accu-Check Smartguide Mobile Application" "Confidence Mobile Application"{ tags "RocheMob" } /* Relationships { tags "" perspectives { "ART" "Platform" "ART" "Personal" "Ownership" "FHIR Stack" } properties { "message standard" "N/A" "message version" "N/A" "message format" "JSON" } url "https://confluence.rochedc.accentureanalytics.com/" } */ Pwd -> cgm "Wheres" "Body Patch" { tags "" perspectives { Security "GCM Patch is worn by the PwD" } properties { } } Pwd -> confidence "Uses" "View" { tags "" perspectives { Security "Accu-Check SmartGuide App is used by the PwD to monitor his/her CGM as well as log Insulin, Meal and Notes data" } properties { } } Pwd -> sl_fe "Uses" "View" { tags "" perspectives { } properties { } } confidence -> ciam "Get user data and consents from" "JSON/HTTP" { tags "" perspectives { Security "Accu-Check SmartGuide App is used by the PwD to monitor his/her CGM as well as log Insulin, Meal and Notes data" } properties { } } confidence -> cgm "Pairs with" "Bluetooth" { tags "" perspectives { Security "The app reads CGM values from the CGM Patch using Bluetooth" } properties { } } confidence -> fhir_stack "Send data to" "JSON-LightFHIR/HTTP" { perspectives { } properties { } } confidence -> app_sett "Send data to" "JSON-LightFHIR/HTTP" { perspectives { } properties { } } //// relationships between Platform systems and components ciam -> account_deletion_sns "Send account deletion request to" "JSON/SNS" { tags "sns" } legal_archive -> account_deletion_sns "Receive request and send start account deletion to" "JSON/SNS" { tags "sns" } account_deletion_sns -> sl_be "Process account deletion request" "JSON/SNS" { tags "sns" } ciam -> ciamcm_common_sns "Send user data changes to" "JSON/SNS" { tags "sns" } ciam -> ciamcm_clinicalstudydeletion_sns "Send clinical study deletion notifications to" "JSON/SNS" { tags "sns" } ciamcm_common_sns -> sl_be "Send user consents changes to" "JSON/SNS" { tags "sns" } ciamcm_clinicalstudydeletion_sns -> sl_be "Send clinical study deletion notifications to" "JSON/SQS" { tags "sns" } complaint_inv -> complaint_tool "Uses" "View data" { tags "" } complaint_service -> complaint_tool "Send application and device data to" "JSON/SNS" { tags "sns" } complaint_tool -> complaint_service "Read user application, device and diagnostics data from" "JSON/HTTP" { tags "" } sl_fe -> sl_be "Send/Receive data" "JSON/HTTP" { } sl_fe -> ciam "Get user data and consents from" "JSON/HTTP" { } sl_fe -> complaint_service "Send application and phone data to" "JSON/HTTP" { } sl_be -> secrets "Get secrets from" "JSON/HTTP" { } sl_be -> logs "Send logs to" "JSON/HTTP" { } // relationship between backend and RDCP sl_be -> rdcp_report "Generate reports using" "JSON/HTTP" { } // relationships between front-end and containers sl_fe -> sl_be.device_management "Initialize data gathering" "JSON/HTTP" sl_fe -> sl_be.data_combined "Get observations data from" "JSON/HTTP" sl_fe -> sl_be.data_profile "Read/Write user profile data from/to" "JSON/HTTP" sl_fe -> sl_be.data_cgm "Read CGM data from" "JSON/HTTP" sl_fe -> sl_be.cgm_integrator "Get initialization status from" "JSON/HTTP" // Relationships between containers and other RDC systems / sub-systems sl_be.cgm_integrator -> fhir_stack "Get new data from" sl_be.cgm_integrator -> app_sett "Get new data from" fhir_stack -> sl_be.data_notification "Notify of new data to" { tags "sns" } app_sett -> sl_be.data_notification "Notify of new data to" { tags "sns" } account_deletion_sns -> sl_be.data_notification "Notify of account deletion to" { tags "sns" } ciamcm_common_sns -> sl_be.data_notification "Notify of user consents changes to" { tags "sns" } ciamcm_clinicalstudydeletion_sns -> sl_be.cs_datadeletion_sqs "Notify of clinical study deletion to" { tags "sns" } // Relationships between containers //// Backend services sl_be.device_management -> sl_be.cgm_integrator "New device pairing" sl_be.data_notification -> sl_be.cgm_integrator "New data notification/Process account deletion" { tags "sqs" } sl_be.cgm_integrator -> sl_be.cgm_integrator_sqs "Pairing notification" "NOT USED"{ tags "sqs" "not-used" } sl_be.cgm_integrator_sqs -> sl_be.cgm_integrator "New pairing to process" "NOT USED"{ tags "sqs" "not-used" } sl_be.cgm_integrator -> sl_be.data_cgm "Write data to" sl_be.cgm_integrator -> sl_be.data_insulin "Write data to" sl_be.cgm_integrator -> sl_be.data_meal "Write data to" sl_be.cgm_integrator -> sl_be.data_profile "Read/Write data from/to" sl_be.cgm_integrator -> sl_be.data_bgm "Write data to" sl_be.cgm_integrator -> sl_be.data_notes "Write data to" ////combined data service sl_be.data_combined -> sl_be.data_insulin "Read data from" { tags "" } sl_be.data_combined -> sl_be.data_meal "Read data from" { tags "" } sl_be.data_combined -> sl_be.data_bgm "Read data from" { tags "" } sl_be.data_combined -> sl_be.data_notes "Read data from" { tags "" } //// database and cache interactions sl_be.data_cgm -> sl_be.sl_db "Write to/Read from" { tags "tcp" } sl_be.data_insulin -> sl_be.sl_db "Write to/Read from" { tags "tcp" } sl_be.data_meal -> sl_be.sl_db "Write to/Read from" { tags "tcp" } sl_be.data_bgm -> sl_be.sl_db "Write to/Read from" { tags "tcp" } sl_be.data_profile -> sl_be.sl_db "Write to/Read from" { tags "tcp" } sl_be.data_notes -> sl_be.sl_db "Write to/Read from" { tags "tcp" } sl_be.device_management -> sl_be.sl_db "Write to/Read from" { tags "tcp" } sl_be.data_cgm -> sl_be.sl_cache "Write to/Read from" { tags "tcp" } sl_be.data_insulin -> sl_be.sl_cache "Write to/Read from" { tags "tcp" } sl_be.data_meal -> sl_be.sl_cache "Write to/Read from" { tags "tcp" } sl_be.data_notes -> sl_be.sl_cache "Write to/Read from" { tags "tcp" } //// containers to sns sl_be.data_cgm -> sl_be.algo_trigger "Notify of new data to" { tags "sns" } sl_be.data_insulin -> sl_be.algo_trigger "Notify of new data to" { tags "sns" } sl_be.data_meal -> sl_be.algo_trigger "Notify of new data to" { tags "sns" } //// sns to subscribed sqs sl_be.algo_trigger -> sl_be.algo_trigger_pd "Notify of new data to" { tags "sns" } sl_be.algo_trigger -> sl_be.algo_trigger_gp "Notify of new data to" { tags "sns" } sl_be.algo_trigger_pd -> sl_be.worker_pd "Get new data message from" { tags "sqs" } sl_be.algo_trigger_gp -> sl_be.worker_gp "Get new data message from" { tags "sqs" } sl_be.worker_pd -> sl_be.wrapper_pd "Send start predition to" { tags "" } sl_be.worker_gp -> sl_be.wrapper_gp "Send start predition to" { tags "" } sl_be.worker_gp -> sl_be.wrapper_short_hypo "Send start predition to" { tags "" } sl_be.wrapper_pd -> sl_be.data_pattern "Get data for prediction from" { tags "" } sl_be.data_pattern -> sl_be.sl_db "Read/Write data from/to" { tags "tcp" } sl_be.data_pattern -> sl_be.sl_cache "Read/Write data from/to" { tags "tcp" } sl_be.data_pattern -> sl_be.handler_notification_sqs "Notify based on reminders of pattern or to" { tags "sqs" } sl_be.worker_gp -> sl_be.handler_notification_sqs "Notify of high-risk for hypo to" { tags "sqs" } //// wrapper to algo containers sl_be.wrapper_pd -> sl_be.cgm_event_detect "Detect events using" { tags "" } sl_be.wrapper_pd -> sl_be.algo_pd "Get prediction from" { tags "" } sl_be.wrapper_gp -> sl_be.algo_gp "Get prediction from" { tags "" } sl_be.wrapper_gp -> sl_be.feature "Get BOB & un-absorbed carbs from" { tags "" } sl_be.wrapper_short_hypo -> sl_be.algo_short_hypo "Get prediction from" { tags "" } sl_be.wrapper_sg -> sl_be.feature "Get BOB & un-absorbed carbs from" { tags "" } sl_be.wrapper_sg -> sl_be.cgm_event_detect "Detect hipo-events using" { tags "" } sl_be.wrapper_sg -> sl_be.wrapper_gp "Detect if a hypo for the next 2 hours has ben predicted by" { tags "" } sl_be.wrapper_sg -> sl_be.algo_sg "Get prediction from" { tags "" } //// analytics monitoring sl_be.analytics_algo -> sl_be.analytics_algo_kinesis "Send to" { tags "kinesis" } sl_be.analytics_algo_kinesis -> bda "Send prediction logs to" { tags "kinesis" } sl_be.analytics_algo -> sl_be.sl_db "Store prediction logs in (must be removed)" { tags "tcp" "not-used" } sl_be.wrapper_pd -> sl_be.analytics_algo "Send prediction output to" { tags "" } sl_be.wrapper_gp -> sl_be.analytics_algo "Send prediction output to" { tags "" } sl_be.wrapper_short_hypo -> sl_be.analytics_algo "Send prediction output to" { tags "" } sl_be.wrapper_sg -> sl_be.analytics_algo "Send prediction output to" { tags "" } //// push notifications sl_be.handler_notification -> sl_be.sl_db "Read/Write the schedules from/to" { tags "tcp" "" } sl_be.handler_notification -> sl_be.handler_notification_sqs "Get data from" { tags "sqs" "" } sl_be.handler_notification -> sl_be.wrapper_sg "Trigger algorithm using" { tags "" } sl_be.handler_notification -> sl_be.data_pattern "Get weekly pattern data from" { tags "" } sl_be.handler_notification -> sl_be.wrapper_short_hypo "Check if user has hypo risk using" { tags "" } sl_be.data_profile -> sl_be.handler_notification_sqs "Notify profile update to" { tags "sqs" "" } sl_be.handler_notification -> push_notif "Send notification to" { tags "" } push_notif -> sl_fe "Send notification to" { tags "push" } //// account deletion sl_be.cgm_integrator -> sl_be.account_deletion_lambda "Start account deletion using" { tags "tcp" } sl_be.cgm_integrator -> account_deletion_sns "Send account deletion status" { tags "sns" } sl_be.account_deletion_lambda -> sl_be.sl_db "Remove data from" { tags "tcp" } sl_be.account_deletion_lambda -> sl_be.sl_cache "Remove data from" { tags "tcp" } //// reports sl_be.report_generation -> sl_be.report_generation_queue "Send report generation request to" { tags "sqs" } sl_be.report_generation_queue -> sl_be.report_request_forwarder "Get report generation request from" { tags "sqs" } sl_fe -> sl_be.report_generation "Send report generation request to" { tags "" } sl_be.report_request_forwarder -> sl_be.report_templates "Get report template link from" { tags "tcp" } sl_be.report_request_forwarder -> sl_be.sl_db "Retrieve data for the report from" { tags "tcp" } sl_be.report_request_forwarder -> rdcp_report "Send report generation request to" { tags "" } rdcp_report -> sl_be.report_templates "Get report template from" { tags "tcp" } rdcp_report -> sl_be.report_request_forwarder "Send report link to" { tags "" } } views { /* Static configuration, styling and properties for views */ properties { "plantuml.url" "https://kroki.io/plantuml" "plantuml.format" "png" "structurizr.softwareSystemBoundaries" "true" "structurizr.enterpriseBoundary" "true" "structurizr.tooltips" "true" } branding { logo documentation_sad/images/static/logo_roche.png } theme https://structurizr.moebiusol.eu/workspace/1/theme styles { element "Internal" { background #0038a8 color #ffffff } element "RocheGateway" { shape RoundedBox width 3900 background grey } element "CGM Patch" { shape Circle color #0038a8 } element "MicroPump" { shape RoundedBox color #c2b280 } element "RocheHCC" { shape Ellipse background #8fbc8f stroke #ff0000 } element "RocheWeb" { shape WebBrowser } element "RocheExt" { background #6C6477 } element "Group" { background #d3d3d3 color #4C4C4C stroke #4C4C4C strokeWidth 10 icon library/icons/rdc_logo.png } element "interface" { background #BD6711 color #ffffff } element "python" { icon library/icons/python.png } element "nodejs" { icon library/icons/nodejs.png } element "java" { icon library/icons/java.png } element "ios_android" { icon library/icons/ios_android.jpg } element "sqs" { shape Cylinder icon library/icons/aws_sqs.png } element "sns" { shape Pipe icon library/icons/aws_sns.png } element "kinesis_stream" { shape Pipe icon library/icons/aws_kinesis_stream.png } element "lambda" { shape RoundedBox icon library/icons/aws_lambda.png } element "rds" { shape Cylinder icon library/icons/aws_rds.png } element "s3" { shape Cylinder icon library/icons/aws_s3.png } element "es" { shape Cylinder icon library/icons/aws_es.png } element "unclear" { background red color green } element "not-used" { background #d3d3d3 color #4C4C4C stroke #4C4C4C strokeWidth 10 opacity 40 } relationship "Relationship" { style solid routing Orthogonal position 80 } relationship "sns" { color blue } relationship "sqs" { color red } relationship "tcp" { color green } relationship "kinesis" { color #8a2be2 } relationship "push" { style dashed color green } relationship "unclear" { color orange thickness 5 } relationship "not-used" { opacity 60 } } /* END - Static configuration and properties for views */ /* Structurizr diagrams */ systemLandscape "Predict-landscape" "Accu-Check Smartguide Predict Landscape" { include * exclude "sl_be -> account_deletion_sns" exclude "rdcp_report -> sl_be" animation { Pwd cgm confidence apiGW app_sett fhir_stack sl_fe sl_be sl_be logs dss devops } } systemContext sl_be "Predict-context" "The Context of the Accu-Check Smartguide Predict system" { include * Pwd ciam complaint_service exclude "ciam -> *" exclude "rdcp_report -> sl_be" exclude "sl_be -> account_deletion_sns" } container sl_be sl_be "Backend for the Smartguide Predict App"{ include * Pwd } filtered sl_be include "Element,Relationship" "sl_be_dev" "Smartlife Container View - Development Environments" filtered sl_be exclude "not-used" "sl_be_prod" "Smartlife Container View - Productive Environments" /* dynamic diagrams */ dynamic sl_be { title "Accu-Check Smartguide Predict - Security and Privacy" PwD -> cgm "Whering the CGM patch" confidence -> cgm "Reads CGM values from" "Bluetooth" PwD -> confidence "Inputs meal, insulin and notes data in" confidence -> fhir_stack "Syncs collected data to" } dynamic sl_be { title "Accu-Check Smartguide Predict - integration with confidence CGM" PwD -> cgm "Whering the CGM patch" confidence -> cgm "Reads CGM values from" "Bluetooth" confidence -> fhir_stack "Syncs collected data to" fhir_stack -> sl_be.data_notification "Notify that new data has ben synced to" sl_be.data_notification -> sl_be.cgm_integrator "Reads notification from" sl_be.cgm_integrator -> fhir_stack "Reads new CGM data point from" sl_be.cgm_integrator -> sl_be.data_cgm "Writes new CGM data to" { { sl_be.data_cgm -> sl_be.sl_db "Stores new CGM data to" } { sl_be.data_cgm -> sl_be.sl_cache "Caches new CGM data for fast retrieval to" } } sl_be.data_cgm -> sl_be.algo_trigger "Notifies that new CGM data has ben saved to" { { sl_be.algo_trigger -> sl_be.algo_trigger_pd "Notifies that new CGM data has ben saved to" } { sl_be.algo_trigger -> sl_be.algo_trigger_gp "Notifies that new CGM data has ben saved to" } } { { sl_be.algo_trigger_pd -> sl_be.worker_pd "Receive notification that new CGM data has ben saved in DB / Cache from" } { sl_be.algo_trigger_gp -> sl_be.worker_gp "Receive notification that new CGM data has ben saved in DB / Cache from" } } { { sl_be.worker_pd -> sl_be.wrapper_pd "Start computing pattern detection using" } { sl_be.worker_gp -> sl_be.wrapper_gp "Send start prediction to" } { sl_be.worker_gp -> sl_be.wrapper_short_hypo "Send start prediction to" } } sl_be.wrapper_pd -> sl_be.data_pattern "Get data for prediction from" { { sl_be.data_pattern -> sl_be.sl_db "Reads data from" } { sl_be.data_pattern -> sl_be.sl_cache "Reads data from" } } sl_be.data_pattern -> sl_be.handler_notification_sqs "Notify based on reminders of patterns to" sl_be.handler_notification_sqs -> sl_be.handler_notification "Get data from" sl_be.handler_notification -> sl_be.wrapper_sg "Trigger algorithm using" sl_be.handler_notification -> push_notif "Send push notification to PwD using" push_notif -> sl_fe "Send push notification to PwD" PwD -> sl_fe "Reads new prediction on" } /* externaly rendered diagrams */ image * "01-SL_DFD_Overview" { image sl_dfd.png title "Predict Data Flow Diagram" } image * "01-${SL_KEY}_Sequence" { plantuml smartguide_predict_sequence.puml title "${SL} Sequence Diagram" } image * "02-${SL_KEY}_DFD" { plantuml smartguide_predict_dfd.puml title "${SL} Data Flow Diagram" } image * "03-${SL_KEY}_app_consent_revoke" { plantuml app_consent_revocation_example.puml title "${SL} - Smartguide app-specific consent revocation example" } } }