System Architecture
VannahHealthCloud platform architecture — components, data flow, and how everything communicates.
Platform Architecture Overview
VannahHealthCloud is built as a microservices-based cloud platform designed for high availability, scalability, and security in medical imaging environments.
High-Level Architecture
┌─────────────────────────────────────────────────────────────────┐
│ Load Balancer / Reverse Proxy │
│ (Nginx / Traefik / CapRover) │
└──────────┬──────────────────┬──────────────────┬────────────────┘
│ │ │
┌─────▼─────┐ ┌──────▼──────┐ ┌──────▼──────┐
│ Web App │ │ DICOM │ │ API │
│ (Next.js) │ │ Gateway │ │ Server │
│ Frontend │ │ (Orthanc) │ │ (REST) │
└─────┬─────┘ └──────┬──────┘ └──────┬──────┘
│ │ │
┌─────▼──────────────────▼──────────────────▼────────────────┐
│ Message Queue / Event Bus │
│ (RabbitMQ / Redis Streams) │
└─────┬──────────────────┬──────────────────┬────────────────┘
│ │ │
┌─────▼─────┐ ┌──────▼──────┐ ┌──────▼──────┐
│ MedDream │ │ PostgreSQL │ │ Object │
│ Viewer │ │ Database │ │ Storage │
│ (DICOM) │ │ │ │ (MinIO/S3) │
└───────────┘ └─────────────┘ └─────────────┘Core Components
1. Web Application (Frontend)
- Technology: Next.js with React
- Purpose: User-facing interface for radiologists, technologists, and administrators
- Features: Study list, worklist management, reporting, admin dashboard
- Hosting: CapRover / Docker container
- URL:
dev.teledokta.co.tz
2. DICOM Gateway (Orthanc)
- Technology: Orthanc DICOM Server
- Purpose: Receives, stores, and serves DICOM images
- Protocols: DICOM (C-STORE, C-FIND, C-MOVE, C-ECHO), DICOMweb (WADO-RS, STOW-RS, QIDO-RS)
- Port: 4242 (DICOM), 8042 (REST API)
- Storage Backend: PostgreSQL + Object Storage (MinIO/S3)
3. MedDream DICOM Viewer
- Technology: MedDream HTML5 Viewer
- Purpose: Diagnostic-quality image viewing in the browser
- Features: MPR, 3D rendering, measurements, annotations, hanging protocols
- Integration: Connected to Orthanc via DICOMweb
4. API Server
- Technology: Node.js / Python REST API
- Purpose: Business logic, authentication, user management, workflow orchestration
- Endpoints: Study management, user CRUD, reporting, integration APIs
- Authentication: JWT tokens with role-based access control (RBAC)
5. Database (PostgreSQL)
- Purpose: Stores metadata, user data, study information, audit logs
- Tables: Users, Studies, Series, Instances, Reports, AuditLogs, Worklist
- Replication: Primary-replica setup for high availability
6. Object Storage (MinIO/S3)
- Purpose: Stores actual DICOM pixel data and attachments
- Features: Versioning, lifecycle policies, encryption at rest
- Capacity: Scales horizontally for petabyte-scale archives
7. Message Queue (RabbitMQ / Redis)
- Purpose: Asynchronous event processing and inter-service communication
- Events: New study received, report finalized, user actions, HL7 messages
- Patterns: Pub/sub, work queues, request-reply
Communication Flow
Image Acquisition Flow
Modality (CT/MR/US)
│
│ DICOM C-STORE
▼
Orthanc DICOM Gateway
│
├── Store metadata → PostgreSQL
├── Store pixel data → MinIO/S3
├── Publish event → Message Queue
│
▼
Event Consumers
├── Notify Web App (WebSocket)
├── Trigger routing rules
├── Update worklist
└── AI pipeline (optional)Image Viewing Flow
Radiologist Browser
│
│ HTTPS Request
▼
Web App (Next.js)
│
│ DICOMweb WADO-RS
▼
Orthanc Gateway
│
│ Retrieve from storage
▼
MedDream Viewer
│
│ Renders in browser
▼
Diagnostic DisplayIntegration Flow
External Systems (RIS/EMR/HMS)
│
│ HL7 v2 / FHIR
▼
Integration Engine
│
├── Parse & validate messages
├── Map to internal models
├── Update database
│
▼
VannahHealthCloud Core
│
├── Modality Worklist (MWL)
├── Study Status Updates
├── Report Distribution
└── Patient SyncDeployment Architecture
Container Orchestration
All services run as Docker containers orchestrated by either:
- CapRover — For simpler deployments (current production setup)
- Kubernetes — For enterprise-scale, multi-site deployments
Network Topology
Internet
│
▼
┌─────────────────┐
│ CDN / WAF │ (Cloudflare)
└────────┬────────┘
│
┌────────▼────────┐
│ Reverse Proxy │ (Nginx / Traefik)
│ SSL Termination│
└────────┬────────┘
│
┌────────▼────────────────────────────────┐
│ Application Network (Docker Bridge) │
│ │
│ ┌──────┐ ┌──────┐ ┌──────┐ ┌────────┐ │
│ │Web │ │Orthanc│ │API │ │MedDream│ │
│ │App │ │ │ │Server│ │Viewer │ │
│ └──┬───┘ └──┬───┘ └──┬───┘ └──┬─────┘ │
│ │ │ │ │ │
│ ┌──▼────────▼────────▼────────▼─────┐ │
│ │ Internal Network (Services) │ │
│ │ PostgreSQL │ MinIO │ RabbitMQ │ │
│ └───────────────────────────────────┘ │
└─────────────────────────────────────────┘Environment Configuration
| Variable | Description | Example |
|---|---|---|
DATABASE_URL | PostgreSQL connection string | postgresql://user:pass@db:5432/vhc |
ORTHANC_URL | Orthanc REST API URL | http://orthanc:8042 |
MINIO_ENDPOINT | Object storage endpoint | minio:9000 |
RABBITMQ_URL | Message queue connection | amqp://user:pass@rabbitmq:5672 |
JWT_SECRET | Authentication secret | <generated-secret> |
MEDDREAM_URL | MedDream viewer URL | https://viewer.example.com |
Scalability Considerations
- Horizontal Scaling: Web app and API server can be scaled behind a load balancer
- Database Scaling: Read replicas for query-heavy workloads
- Storage Scaling: MinIO clusters for distributed object storage
- Caching: Redis for session management and frequently accessed study metadata
- CDN: Static assets and viewer resources served via CDN for global performance
VannahHealthCloud Documentation
Comprehensive technical documentation for VannahHealthCloud — Cloud PACS, DICOM workflows, system architecture, and medical imaging infrastructure.
DICOM Workflows
End-to-end DICOM imaging data flows — acquisition, routing, storage, retrieval, and viewing in VannahHealthCloud.