Clean good practices during development

MaMNT are aiming to keep technical debt to a minimum, and to maximize agility, extensibility, security and maintainability. Sure, we could rush ahead, building a quivering monolith on the brink of collapse. But this is about putting pride in your craft!

Code Repository

The code repository is hosted in GitHub as a mono-repo, split into individual subdirectories for different parts of our solution. Mono-repo is used by software giants such as Google and Microsoft, to make testing and development easier across apps and products.

Continuous Delivery

Continuous delivery is achieved through GitHub Actions: The gRPC server and Registration app are built and deployed to Azure App Service whenever changes to the apps are pushed to the main branch.

The Github Actions workflow (steps are minimized to save space)
Deployment complete!

Secure secret storage

Of course, client secrets are kept out of the code. Secrets are kept in Azure Key Vault, and are injected as environment variables in the App Service.

The appsettings.json file does not include the Client Secret.
The secret (Azure__ClientSecret) is added in Azure Web App through a reference to Key Vault, where the secret is stored.

Inversion of Control

Following Microsoft and industry best practices, the software project uses Dependency Injection to achieve Inversion of Control. Our classes are stateless, and dependencies are injected from the service provider. Classes depend on abstractions instead of implementations, to make the solution more “plug-and-play” and simplify unit testing.

The GrpcClient class takes a StatusUpdateHandler as well as a Logger from the service collection. Appsettings are injected as well.
The GrpcClient installer.
Adding the required services in an app that uses the GrpcClient.

SOLID principles

We adhere to all “SOLID principles”. All classes and methods do one thing and do them well. Classes depend on abstractions instead of implementations. Interfaces are small and interchangeable.