Tuesday, June 25, 2024
HomeC#The First .NET Aspire Ebook! – blogs.cninnovation.com

The First .NET Aspire Ebook! – blogs.cninnovation.com


My new e-book is obtainable! It’s the primary e-book about .NET Aspire, protecting all of the elements of making microservices with .NET!

.NET Aspire gives new instruments and libraries to make it straightforward creating, debugging, and deploying services-based functions with .NET. I’m loving it and labored arduous to create a e-book!

Making a recreation utility

Studying and dealing via the e-book, you not solely be taught loads, however it’s additionally enjoyable! From the second chapter on you create an utility to run a recreation, making use of a number of NuGet packages which can be obtainable by way of NuGet, so that you don’t want to consider the algorithms and might focus on the elements necessary creating microservices!

Companies operating utilizing Microsoft Azure

Working on Microsoft Azure, the applying makes use of Azure Container Apps, and several other providers. Within the subsequent picture you see the interplay with a bot service which performs a number of video games. In fact, different purchasers utilizing Blazor, WinUI, WPF, Uno Platform, and Avalonia UI can be found as properly. Nonetheless, the bot service is quicker in enjoying full video games which helps with testing and monitoring. The bot service is triggered from a message within the queue and sends requests to the sport APIs service utilizing gRPC.

Codebreaker - Async communication with queues

The subsequent picture exhibits the asynchronous communication from the sport APIs service. On recreation completion, an occasion is fired – utilizing Azure Occasion Hub. Subscribers to those occasions are the dwell service which permits dwell monitoring of video games, and the rating service. The rating service has its personal database to retailer recreation info used to calculate ranks.

Codebreaker – Async communication with events

Different Azure providers used are Azure App Configuration, Azure Key Vault, Azure Load Testing, Azure Cosmos DB, and plenty of extra!

Companies operating in an on-premises surroundings

Within the e-book you’ll see providers that may run on premises as properly. As an alternative of utilizing Azure, the applying can run utterly impartial of Azure. For instance, as an alternative of utilizing Azure Occasion Hub, the choice choice that’s used is Apache Kafka. The appliance is deployed to a Kubernetes cluster utilizing Aspir8.

The e-book tour

With the e-book I take you at a tour throughout all of the necessary elements when creating microservices, and .NET Aspire is used all the way in which!

Half 1: Creating Microservices with .NET

  • Chapter 1, Introduction to .NET Aspire and Microservices provides an introduction of .NET Aspire, and what’s concerning the utility we develop.
  • Chapter 2, Minimal APIs – Creating REST providers kicks off creating the sport APIs service. It’s already operating, and you’ll play video games (simply utilizing HTTP information).
  • Chapter 3, Writing knowledge to relational and NoSQL databases provides persistence. The video games are now not simply saved in-memory, however make use of SQL Server and Azure Cosmos DB. Extra time to play a recreation!
  • Chapter 4, Creating Libraries for Shopper Functions provides shopper libraries and console functions. One shopper library simply makes use of the HTTP shopper manufacturing facility, whereas the second makes use of Microsoft Kiota – this instrument permits to create the shopper from the Open API definition.

Half 2: Internet hosting and Deploying

  • Chapter 5, Containerization of Microservices – right here you be taught all you should learn about Docker, and take benefits of the built-in performance of dotnet publish which permits creating Docker photos with out the necessity to create Dockerfiles.
  • Chapter 6, Microsoft Azure for Internet hosting Functions makes use of Azure providers. You be taught concerning the core providers utilized by the applying, and eventually publish the applying to Azure with the Azure Developer CLI.
  • Chapter 8, CI/CD with GitHub Actions provides CI/CD to the deployment story. GitHub actions shall be used to mechanically deploy the applying in addition to NuGet packages for the shopper functions.
  • Chapter 9, Authentication and Authorization provides B2C to permit customers to register – and ASP.NET Core Identities to supply this performance in an on-premises surroundings.

Half 3: Troubleshooting and Scaling

  • Chapter 10, All about testing the answer provides unit checks and integration checks. .NET Aspire gives take a look at template for simpler testing of providers. You’ll additionally be taught utilizing Microsoft Playwright to create API checks.
  • Chapter 11, Logging and monitoring – oh, this is a vital chapter to know what’s happening with the providers. Not solely will you employ .NET structured logging, distributed tracing, and metrics with Open Telemetry and the .NET Aspire Dashboard, Azure App Insights and Log Analytics – additionally Grafana and Prometheus shall be used with the on-premises model.
  • Chapter 12, Scaling Companies – right here you employ Azure Load Testing to create an enormous load (you may keep away from creating the large load and simply learn concerning the outcomes), and each scale the providers utilizing extra CPU and reminiscence, in addition to extra situations – vertical and horizontal scaling. We’ll additionally enhance efficiency by utilizing a cache and examine the variations.

Half 4: Extra communication choices

  • Chapter 13, Actual-time messaging with SignalR makes use of one other communication method with ASP.NET Core SignalR, the dwell service sends details about accomplished video games to all linked purchasers.
  • Chapter 14, gRPC for binary communication adjustments from REST providers to make use of gRPC for communication between providers. Decreasing CPU, reminiscence, and knowledge switch utilization can cut back the sum of money wanted.
  • Chapter 15, Asynchronous communication with messages and occasions provides Apache Kafka and Azure Occasion Hub and the rating service: which consumer has the very best recreation run of the week?
  • Chapter 16, Working the applying on-premises and within the cloud makes use of Aspir8 to deploy the applying to Kubernetes, combines performance from earlier chapters, and investigates what’s subsequent.

As you see this provides you necessary info – not solely when making a microservices utility structure – however you’ll additionally learn info that helps with easier distributed options. All the way in which, tooling, orchestration, and elements utilizing .NET Aspire comes into play.

As you see this provides you nice info – not solely when making a microservices utility structure – however you’ll additionally learn info that helps with easier distributed options. All the way in which, tooling, orchestration and elements utilizing .NET Aspire comes into play.

All the way in which, you may play a recreation to unravel the code of 4 or 5 matching colors, or matching colors and shapes.

Codebreaker Game play

Now, get the e-book!

You’ll get pleasure from studying and enjoying (e-book or print):

Packt Publishing – Pragmatic Microservices

Amazon US – Pragmatic Microservices

Amazon DE – Pragmatic Microservices

or out of your most popular e-book distributor.

Since some years I’m utilizing a Packt subscription myself to learn all of the books obtainable there! In fact, this contains the Pragmatic Microservices e-book!

I had a tour working with .NET Aspire previews, repeatedly updating the code with the enhancements coming from .NET Aspire. It was a problem, but in addition enjoyable to affect .NET Aspire. I’m positive you want my new e-book! Trying ahead to your suggestions!

Take pleasure in!
Christian

Extra Info

Extra details about .NET Aspire is obtainable in my e-book and my workshops.

Supply code of Pragmatic Microservices

Extra Codebreaker Repos

.NET Workshops

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments