DEV Community

Cover image for MFlix - A C# .NET 5 Project
Douglas Minnaar
Douglas Minnaar

Posted on • Updated on

MFlix - A C# .NET 5 Project

Intro

I have created a project that demonstrates how to build 3 API's using 3 different API tehnologies, namely GraphQL, gRPC, and REST (HTTP). I have also chosen to use MongoDB as my database.

You can find the project on github. The project has been built and tested on both Linux and Windows 10 environments using Visual Studio Code and .NET 5.

I provide more detail about the project in the project README.

The summary of the project thus far is as follows:

The following diagram provides a high-level view of what I am building.

mflix-hla-1

Initially, I thought about creating this project as part of a series of blog posts. However, I decided to instead build the application first. MFlix is by no means complete, but now is a good time to start sharing the work being done due to a number of interesting aspects that I am working on. In the coming months, I will continue to build out MFlix. Also, if there is interest, I would like to provide a series of blog posts where I discuss some of the more interesting aspects of the project.

About MFlix

I chose MFlix as the name for this project because I am using one of the sample databases provided by MongoDB called MFlix. The MFlix database is composed of collections of movie related data. I provide more detail in the MongoDB section where I explain how to get a copy of the MFlix database. Therefore, because of the database name, and the fact that MFlix is a short and catchy name, I decided to go with MFlix.

The primary purpose of MFlix is to demonstrate how to build gRPC, REST (http), and GraphQL API's using C# and the .NET Framework. In order to do this, I have created a contrived use-case that will allow me to demonstrate how to build different API's for different needs. Each API demonstrates how to address the following requirements:

  • Error handling
  • Logging
  • Caching
  • Security
  • Dependency Injection
  • Configuration
  • How to do paging, filtering, and sorting via the API

The secondary purpose of MFlix is to demonstrate how to work with different technologies, frameworks, and libraries using the C# .NET Framework. The different topics that will be demonstrated are as follows:

  • Developing with MongoDB and C#
  • Preparing a local development environment using Docker and Docker-Compose
  • Working with MongoDB database
  • Working with SEQ as a log server

Lastly, I cover a useful set of tools that can be used to test the various API's. Some of the tools covered are as follows:

Outro

This was a quick introduction to MFlix. I consider what I have done thus far as my "MVP (Minimum Viable Product)". Depending on the feedback, I may follow up with a series of blog posts and maybe a few videos on topics relating to technology and frameworks used within the project. If you like what you see so far, please star the MFlix project.

Top comments (1)

Collapse
 
rmaurodev profile image
Ricardo

Love It. Please continue.... :)