Jamie Taylor peels back the details on running a .NET Core web application in production. Everything is hosted for free on Azure.

In this episode of Running in Production, Jamie Taylor goes over how he
built Discworld Disorganizer which is a Discworld
book series search engine. It’s written in .NET Core and hosted for free on
Azure. It’s been running in production since 2017.

Jamie developed this app to scratch his own itch to help figure out which books
he already owns. The API portion of
the app is a separate app that is public and free to use. I learned a lot about
the .NET eco-system and even Discworld in this episode thanks to Jamie!

Topics Include

0:59 – .NET Core is open source and runs on Windows, MacOS and Linux
1:39 – The front-end is using Angular 2 and the back-end is using ASP .NET Core
2:33 – Differences between ASP .NET Core, .NET Core and picking a programming language
3:10 – .NET lets you write your program in multiple languages (C#, F# and VB.Net)
4:49 – Jamie picked C# primarily due to previous experience using it
6:35 – Jamie learns best by audio / video but also by building real projects
7:30 – Learning by example vs learning by theory
8:22 – Discworld is a series of comic fantasy books
9:52 – The world is a disc held up by 4 elephants standing on a turtle swimming in space
10:43 – Jame’s app lets you search for Discworld books, characters and locations
11:47 – He built the app to help him figure out which books he already has
12:34 – The search is handled by a free and open source RESTful API
13:58 – The API uses Swagger
that uses code as documentation to see example usages
14:43 – ASP .NET Core lets you pick server side templates or an API back-end
16:27 – Jamie wanted to learn a new front-end tool so he went API based with Angular 2
17:19 – The front-end and back-end take a few seconds to warm up due to Azure’s free tier
18:53 – That spin up time is similar to Heroku’s free tier and also how IIS works
20:00 – SQLite is being used to store the books and everything else on the back-end
21:18 – The API has a delete database endpoint but it’s protected by a strong password
21:55 – Entity Framework Core is used as an ORM (Object-relational mapper)
23:04 – Subtle differences between different databases like PostgreSQL and SQLite
23:48 – Maybe dropping EF Core for Dapper which is a light weight ORM
24:28 – Trade offs between using a high powered ORM and writing raw SQL
24:48 – The code itself uses the LINQ library from Microsoft to query the data
26:36 – The code base is 18 months old and it doesn’t use Docker, but it might soon
28:18 – Azure’s free tier (at the time) gave you free resources but you didn’t pick the specs
29:14 – Microsoft is very open about their platform, you can even visit their data centers
30:19 – Infrastructure as a Service (IaaS) vs Platform as a Service (PaaS)
32:51 – You get free SSL certificates with Azure’s PaaS offering on their domain
33:48 – You can use a custom domain name with Azure’s paid plans
35:09 – Walking through the deploy process from development to production
35:49 – After pushing to GitHub, AppVeyor (CI / CD) takes over and deploys it to Azure
37:44 – AppVeyor was used because Azure Pipelines wasn’t really around yet
38:14 – Using a third party CI / CD tool has less vendor lock-in too
39:49 – .NET Core rolls everything up into a single binary file that can be deployed
41:02 – Both the API back-end and Angular front-end have separate binary files
41:52 – Having single binary deployments makes it easier to manage deploys
42:29 – Most folks can run his project as long as you have the .NET Core run-time installed
45:05 – Jamie uses VSCode and JetBrains Rider instead of Visual Studio
47:23 – Dealing with Azure database backups using a real DB server and SQLite
48:35 – There is monitoring that keeps track of delete actions from the back-end API
49:52 – This delete action API endpoint wouldn’t be used for client work or a “real” project
50:25 – Jamie still uses his own app today to help keep track of which books he has
52:25 – Best tips? Focus on the data relationships before writing your code
53:22 – Switching the API from Discworld to Stephen King books, it works!
56:53 – You can find Jamie on GitHub and
@dotnetcoreshow
on Twitter where he posts updates about his .NET Core Podcast.
He also has an https://about.me/thejamietaylor page

Links

📄 References

https://docs.microsoft.com/en-us/aspnet/core/?view=aspnetcore-3.0
https://docs.microsoft.com/en-us/ef/core/
https://en.wikipedia.org/wiki/The_Art_of_Computer_Programming
https://en.wikipedia.org/wiki/Discworld
https://en.wikipedia.org/wiki/Open_API
https://en.wikipedia.org/wiki/HATEOAS
https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/concepts/linq/
https://en.wikipedia.org/wiki/Field-programmable_gate_array
https://en.wikipedia.org/wiki/PKCS_12
https://www.atlassian.com/git/tutorials/comparing-workflows/gitflow-workflow

⚙️ Tech Stack









































































































































































































































dotnet-core →

















































































































































































































































































































































































































































































































































































































































































angularjs →













































































































































































appveyor →











































































































































































































































































































































































































































































































































































































































































































































azure →







































































































































































































































































































































































































































































































































































c-sharp →





































































































































































































































































































































iis →





































































































































































































































































































































































































open-source →









































































































































































































































































































































































































































































































sqlite →





























































































































































































































































































































Support the Show

This episode does not have a sponsor and this podcast is a labor of love. If
you want to support the show, the best way to do it is to purchase one of my
courses or suggest one to a friend.


Dive into Docker is a video course that takes you from not knowing what Docker is
to being able to confidently use Docker and Docker Compose for your own apps.
Long gone are the days of "but it works on my machine!". A bunch of follow
along labs are included.


Build a SAAS App with Flask is a video course where we build a real
world SAAS app that accepts payments, has a custom admin, includes high test
coverage and goes over how to implement and apply 50+ common web app features.
There's over 20+ hours of video.

Twitter Mentions