Skip to content

Repository files navigation

Medical system

Medical system is a small application build with ASP.NET 5 and EF to document medical records. User can store doctor, patient and consultation information in this application with their web browser. This is a proof of concept of how we can use microservice with ASP.NET 5.

image

This is influenced by .NET Microservices Sample Reference Application

CI CD status

ModuleStatus
Doctor serviceDoctor service CI CD
Patient servicePatient service CI CD
Consultation serviceConsultation service CI CD
Web gatewayWeb gateway CI CD
Web mvcWeb mvc CI CD
Doctor sync jobDoctor sync job CI CD
Patient sync jobPatient sync job CI CD
Health check dashboardHealth check dashboard CI CD

Tech stack

ModuleTech
Backend apisASP.NET 5 gRPC service
GatewayASP.NET 5 Web Api
Frontend web applicationASP.NET 5 MVC
JobsAzure function
Database accessEntity Framework
DatabaseSQL Server
Unit testNUnit

Architecture diagram

Medical system architecture

Docker images

This app is in docker images and stored in dockerhub.

ImagesDockerhubVersion
Doctor servicehttps://hub.docker.com/r/45862391/doctorserviceDocker Image Version (latest by date)
Patient servicehttps://hub.docker.com/r/45862391/patientserviceDocker Image Version (latest by date)
Consultation servicehttps://hub.docker.com/r/45862391/consultationserviceDocker Image Version (latest by date)
Web gatewayhttps://hub.docker.com/r/45862391/webgatewayDocker Image Version (latest by date)
Web mvchttps://hub.docker.com/r/45862391/webmvcDocker Image Version (latest by date)

Hosting

When a new release is created then this app is stored inside a docker image and push to docker hub through CI CD. Hosting in Azure is not done as a part of CI CD. That needs to be done manually.

  • Create a new resource group in Azure
  • In that resource group create the following resources
    • App Service Plan for Linux
    • Web App for Doctor service, Patient service, Consultation service, Web Gateway and Web Mvc
    • SQL Server
    • Database for Doctor service, Patient service and Consultation service
  • Create tables in the databases for Doctor service, Patient service and Consultation service
  • Update the connection strings in the web app configuration for Doctor service, Patient service and Consultation service
  • Update api endpoint urls in Web Gateway and Web Mvc

Now open the Web App URL in web browser for Web Mvc and you should access the app.

The future plan is to deploy the services in AKS.

How to run

You need Visual Studio 2019, ASP.NET 5, Entity Framework, Azure tools for Visual Studio 2019 and SQL Server 2016 to work on this solution locally.

  • Clone the repo
  • Create the databases and tables with the script provided in the repo.
  • Update the connection strings and other configs in appsettings.Development.json file in different projects as applicable to your local settings before executing this app.
  • Open the solution in Visual Studio
  • Set the below projects as startup projects
    • Doctor service
    • Patient service
    • Consultation service
    • Web gateway
    • Web frontend
  • Press F5 to run

Releases

Packages

Used by

Contributors

Languages