How ihtsdo/health-data-analytics works
Project type and purpose
• This is a full-stack, modular healthcare analytics application (“Snolytical”) with:
• A built-in patient data generator (“generator” module)
• A simple domain model (“model” module)
• A Spring Boot REST API server with ingestion pipeline and Elasticsearch persistence (“server” module)
• A Vue.js web UI (“ui” module)
• Optional Synthea JSON modules for richer synthetic data (“synthea-modules”)
File structure
• Top-level Maven modules:
• generator/ — Java patient-population generator
• model/ — plain Java POJOs (Patient, ClinicalEvent, etc.)
• server/ — Spring Boot application: ingestion, services, REST controllers, Elasticsearch config, Debian packaging
• ui/ — Vue.js single-page application
• synthea-modules/ — sample Synthea JSON modules
• Key patterns:
• Layered architecture in server: config → ingestion → service → REST controllers → repository
• Plugin-style ingestion sources (FHIR, NDJSON local file, real-time) via HealthDataIngestionSource interface
• Data flow orchestrated by the server CLI arguments for import vs. run
README for additional insights
• Core use cases: load Bulk FHIR or native NDJSON patient data → analyze cohorts → run statistical tests → show results on web UI
• Dependencies: Java 17, Spring Boot, Elasticsearch 8.11.x, Vue.js, Maven
• Client Browser / Web UI (Vue.js SPA)
• API Server (Spring Boot)
• Ingestion Pipeline (plugin modules for FHIR, local-NDJSON, real-time JMS, etc.)
• Domain Model (Patient, ClinicalEvent classes from model/)
• Persistence / Search Engine (Elasticsearch cluster)
• Data Generators:
• Built-in generator CLI (generator/)
• Synthea bulk FHIR generator + Synthea modules (synthea-modules/)
• External Services:
• FHIR Terminology Server (Snowstorm) for SNOMED CT lookups
• Optional CPT code loader (files on disk)
1. Data Generation → produces NDJSON FHIR files
2. CLI import arguments (–import-population-fhir or –import-population) invoke ingestion pipeline
3. Ingestion modules fetch or read resources → map to internal ClinicalEvent/Patient model
4. Service layer aggregates, validates, and hands off to repository
5. Repository writes to Elasticsearch indexes (patient, subset, etc.)
6. When server is running, REST controllers expose endpoints consumed by UI
7. UI issues HTTP requests → Server controllers → Service layer → Elasticsearch → back to UI
c. Architectural patterns and design principles:
• Layered MVC-style architecture in server
• Dependency injection (Spring Boot) for config, ingestion sources, services
• Plugin pattern for ingestion sources
• Separation of concerns between data generation, API, and UI
d. Key technologies/frameworks:
• Java 17, Spring Boot, Maven
• Elasticsearch 8.11.x
• Vue.js, TypeScript
• FHIR (NDJSON), SNOMED CT terminology service
Elements
• Labels: name each module/component (e.g., “FHIR Ingestion Source”)
• Orange cloud for external FHIR/SNOMED service
• Purple parallelogram for UI
Detail recommendations
• Domain model package as an internal sub-block of the server
• Optionally, show sequence:
1. Generate synthetic data
2. Import into API
3. Run analytics via REST
4. In UI