OpenCRVS
v1.3
v1.3
  • 👋Introduction
  • Product Specifications
    • Functional Architecture
    • Workflow management
    • Status Flow Diagram
    • Users
      • Examples
    • Core functions
      • 1. Notify event
      • 2. Declare event
      • 3. Validate event
      • 4. Register event
      • 5. Print certificate
      • 5. Issue certificate
      • 6. Search for a record
      • 7. View record
      • 8. Correct record
      • 9. Verify record
      • 10. Archive record
      • 11. Vital statistics export
    • Support functions
      • 10. Login
      • 11. Audit
      • 12. Deduplication
      • 13. Performance management
      • 14. Payment
      • 15. Learning
      • 16. User support
    • Admin functions
      • 17. User management
      • 18. Comms management
      • 19. Content management
      • 20. Config management
    • Data functions
      • 21. Legacy data import
      • 22. Legacy paper import
  • Technology
    • Architecture
      • Performance tests
    • Standards
      • FHIR Documents
        • Event Composition
        • Person
        • Registration Task
        • Event Observations
        • Locations
    • Security
    • Interoperability
      • Create a client
      • Authenticate a client
      • Event Notification clients
      • Record Search clients
      • Webhook clients
      • National ID client
      • FHIR Location REST API
      • Other ways to interoperate
  • Default configuration
    • Intro to Farajaland
    • Civil registration in Farajaland
    • OpenCRVS configuration in Farajaland
      • User / role mapping
      • Application settings
      • Declaration forms
      • Certificate templates
    • Business process flows in Farajaland
  • Setup
    • 1. Establish team
    • 2. Gather requirements
    • 3. Installation
      • 3.1 Set-up a local development environment
        • 3.1.1 Install the required dependencies
        • 3.1.2 Install OpenCRVS locally
        • 3.1.3 Starting and stopping OpenCRVS
        • 3.1.4 Log in to OpenCRVS locally
        • 3.1.5 Tooling
      • 3.2 Set-up your own country configuration
        • 3.2.1 Fork your own country configuration repository
        • 3.2.2 Set up administrative address divisions
          • 3.2.2.1 Prepare source file for administrative structure
          • 3.2.2.2 Prepare source file for statistics
        • 3.2.3 Set up CR offices and Health facilities
          • 3.2.3.1 Prepare source file for CRVS Office facilities
          • 3.2.3.2 Prepare source file for health facilities
        • 3.2.4 Set up employees & roles for testing or production
          • 3.2.3.1 Prepare source file for employees
          • 3.2.3.2 Configure role titles
        • 3.2.5 Set up application settings
          • 3.2.5.1 Configuring Metabase Dashboards
        • 3.2.6 Configure certificate templates
        • 3.2.7 Configure declaration forms
          • 3.2.7.1 Configuring an event form
        • 3.2.8 Seeding your local development environment database
          • 3.2.8.1 Clearing your local development environment database
        • 3.2.9 Countryconfig APIs explained
          • 3.2.9.1 Managing language content
      • 3.3 Set-up a server-hosted environment
        • 3.3.1 Provision your server nodes with SSH access
        • 3.3.2 Provision environment
        • 3.3.3 Provision a comms gateway
        • 3.3.4 Set up an SMTP server for OpenCRVS monitoring alerts
        • 3.3.5 Setup DNS A records
        • 3.3.6 Deploy (Automated & Manual)
        • 3.3.7 Seeding & clearing data on a server
        • 3.3.8 Automated & manual backup and manual restore
    • 4. Functional configuration
      • 4.1 Configure application settings
      • 4.2 Configure registration periods and fees
      • 4.3 Create new user roles
      • 4.4 Managing system users
    • 5. Testing
    • 6. Go-live
    • 7. Monitoring
      • 7.1 Application logs
      • 7.2 Infrastructure health
      • 7.3 Routine monitoring checklist
      • 7.4 Setting up alerts
      • 7.5 Managing a Docker Swarm
  • General
    • Contributing
    • Releases
      • v1.3.5: Release notes
      • v1.3.4: Release notes
      • v1.3.2: Release notes
      • v1.3.1: Release notes
      • v1.3.* to v1.3.* Migration notes
      • v1.3.0: Release notes
      • v1.2.* to v1.3.* Migration notes
        • v1.2 to v1.3: Form migration
      • v1.2.1: Release notes
      • Patch: Elasticsearch 7.10.2
      • v1.2.0: Release notes
      • v1.1.* to v1.2.* Migration notes
      • v.1.1.2: Release notes
      • v.1.1.1: Release notes
      • v1.1.0: Release notes
    • Interoperability roadmap
    • Product roadmap
Powered by GitBook
On this page
  • Open source dependencies
  • OpenCRVS packages
  1. Technology

Architecture

Previous22. Legacy paper importNextPerformance tests

Last updated 1 year ago

The technical architecture of OpenCRVS was designed to conform to the and interoperate using . FHIR is a global standard application programming interface or (API) for exchanging electronic health records.

By following the OpenHIE framework, OpenCRVS seamlessly connects civil registration to health services and other systems. Firstly, by utilising the OpenHIE interoperability reference middleware , a FHIR standard enterprise service bus; and secondly, by using a scalable, modular, NoSQL FHIR datastore, called .

We use OpenHIM to receive birth and death notifications from a hospital setting, and expose registration events to any other technical system via an API gateway e.g. , or .

OpenCRVS business functions are designed using modular, event-driven . Each micro service and every OpenCRVS component is independently scalable in private or public cloud, in large or small data centres, and easy to manage, load balance and network using included configurations.

OpenCRVS builds on these sound principles by additionally providing:

  • Easy country configuration via simple csv files and a configuration UI.

  • Standards-based multi-language content management.

  • A market-leading, powerful search and de-duplication engine powered by .

  • Real-time performance analytics powered by the time-series database .

  • An Amazon S3 compatible object store for storing supporting documentation attachments powered by .

  • Increased performance by the use of , reducing HTTP requests between client and server.

  • An automated continuous integration, delivery and testing suite.

  • A single JS, codebase for backend, desktop and mobile using for offline and low-connectivity access.

  • External server and application health monitoring using

  • Automatic SSL configuration

  • SMS 2-Factor Authentication with well defined user role authorization privileges

OpenCRVS is a full-stack that is designed to give you the lowest possible .

Open source dependencies

Docker Swarm

  • Many countries may be located far from a high-quality data-centre above Tier 2.

  • Many countries may not legally support international data storage of citizen data on a public cloud. Getting the legal approval for external storage of citizen data requires regulatory change which can take a considerable amount of time.

  • Because some countries may not be able to maintain complex software independently, we are considering a SaaS solution, provided enough countries get regulatory approval. Over time, this situation appears to be slowly evolving and we are monitoring it closely.

Previously unskilled system administrators can quickly up-skill in the techniques of private cloud infrastructure management using Docker Swarm. We wanted to democratise containerisation benefits for all countries.

Is there a plan for Kubernetes?

Hearth MongoDB Database layer

ElasticSearch

De-duplication management to ensure data integrity is essential to any civil registration system. A fast search engine lowers operational costs and improves the user experience for frontline staff.

InfluxData

OpenHIM enterprise service bus, interoperability Layer

OpenCRVS packages

Microservice business layer packages

The OpenCRVS microservice architecture enables continuous evolution of its business requirements.

Client application packages

Support packages

Automated testing support

Our international development teams work in an Agile way, in tandem with local development resources and human-centred designers, following the methodology, to rapidly design, build, deploy, test and maintain OpenCRVS releases.

The following dependencies are automatically provisioned alongside the OpenCRVS Core in containers in a Docker Swarm on Ubuntu.

was chosen by our architects in 2018 for it's lack of requirement of other essential dependencies, it's close alignment with Docker and it's simplicity in terms of installation and monitoring on a , on bare metal servers with headless . Why not use AWS, public cloud SaaS or serverless you might be thinking?

We are working on a migration now that Kubernetes has become a more mature, easier to use and configure solution, thanks to dependencies like Helm and other plugins increasing popularity since 2018. In the meantime, Docker Swarm makes it easy to commence containerised microservice package distribution privately, automatically configures a "round robin" load balanced cluster, and provides Service Discovery out-the-box.

In order to support configuration for limitless country scale, OpenCRVS was designed for , built on , and aligned to a globally recognised healthcare standard.

Massively scalable and extensible, is an OpenSource NoSQL database server originally built by the OpenCRVS founding member , using interoperable v4 ( Accredited, Fast Healthcare Interoperability Resources) as standard.

We extended to support the civil registration context. Our civil registration FHIR standard is described .

OpenCRVS uses , an industry standard, NoSQL document orientated, real-time de-duplication & search engine. Lightning fast, intelligent civil registration record returns are possible, even with imprecise “fuzzy” search parameters.

ElasticSearch is also used with for application and server health monitoring. \

The hyper-efficient "time series database" is used in our stack for "big data" performance insights. Millisecond level query times facilitate civil registration statistical queries over years of data, disaggregated by gender, location and configurable operational and statistical parameters. \

The is a NodeJS enterprise service bus designed to ease interoperability between OpenCRVS and external systems such as Health & National ID. It provides external access to the system via secure APIs. OpenHIM channels and governs internal transactions, routing, orchestrating and translating requests into between services and the database layer.

The core of OpenCRVS is a monorepo organised using . Each package reports unit test coverage in . Following the , 1 service per container model, every package is independently scalable in a single container.

\

The microservices are written in (a strictly typed superset of JavaScript that compiles to JavaScript) and NodeJS using the framework.

Each microservice in OpenCRVS has no knowledge of other services or business requirements in the application, and each exposes it’s capabilities via secured APIs.

- the authentication microservice for OpenCRVS, token generation and management in . Our client applications are protected by SMS . Our apps and microservices utilise for JWT tokens.

- a shared library package that all microservices use in order to validate JWTs

- an application configuration microservice to power a configuration GUI for forms, application settings and certificates

- the and API gateway for the OpenCRVS client. allows OpenCRVS to perform much faster and more responsively in remote areas by drastically reducing the number of HTTP requests that are required in order to render a view in the presentation layer. The OpenCRVS GraphQL Gateway is a JWT protected server that requests and resolves resources from via into GraphQL, for easy consumption in the client applications.

- the civil registration metrics and analytics microservice using the time series database.

- the microservice that manages SMS communications from OpenCRVS, communicating with a choice of 2 3rd party SMS Gateways.

- the search microservice for OpenCRVS using

- the user management microservice for the OpenCRVS client. User permissions and roles can be centrally managed, supporting IT organisations that conform to certification.

- the OpenCRVS business process orchestration microservice, mediating civil registration vital event status and audit updates.

- the login UI client built in .

- the OpenCRVS UI client for civil registration built in .\

Using an Android for our client applications means that we can take advantage of offline functionality and native mobile features using , without the overhead of maintaining multiple web and mobile codebases and respective App/Play Store releases.

In remote areas, registrars can save a configurable number of registrations offline on their mobile phone, using .

Client dependencies and enablers include:

Easy build configuration with , ,

Multi-lingual content management support using

ES6 JS component styling using

Fully configurable, high performance form management using

Pure JavaScript, client side, offline PDF certificate generation using

Read-only application state management using

Unit tests coverage with & UI component tests.

- performance tests for OpenCRVS using the framework.

- a UI component library package for the clients using

OpenCRVS Core displays enforced 80% unit testing coverage on git. We supply example e2e UI test scripts using and cover the main registration business functionality in those tests.

Because the OpenCRVS Form UI is configurable to your country, the end-to-end testing scripts are located in our so you can copy this approach and customise them depending on the structure of your published form.

Open Health Information Exchange (OpenHIE) architectural standard
HL7 (Fast Healthcare Interoperability Resources) or FHIR
OpenHIM
Hearth
MOSIP foundational national ID
DHIS2 health Information Management
microservices
Docker Swarm
ElasticSearch
Influx
Minio
GraphQL
TypeScript
Progressive Web Application technology
Kibana
LetsEncrypt
"total cost of ownership"
Scrum
docker
Docker Swarm
Tier 2 private data centre
Ubuntu OS
Kubernetes
NoSQL
MongoDB
Hearth
Jembi Health Systems
Health Level 7
FHIR
ANSI
FHIR
here
ElasticSearch
Kibana
Influx
OpenHIM (Health Information Mediator)
FHIR
Lerna
Jest
microservice
docker
TypeScript
HapiJS
JWT
auth
JWT
Redis
2-Factor Authentication
OAuth best practices
commons
config
gateway
GraphQL
Apollo
GraphQL
Apollo
FHIR
Hearth
OpenHIM
metrics
Influx
notification
search
ElasticSearch
user-mgnt
ISO27001
workflow
login
React
client
React
progressive web application
Workbox
IndexedDB
npm
create-react-app
craco
typrescript-eslint
Format JS
styled-components
formik
pdfmake
redux
Jest
Enzyme
integration
K6
components
React Storybook
Codecov
Cypress
example country configuration server for Farajaland
1MB
Application services and network diagram.png
image