Home Archive ASP.NET Core middleware, DI, and perf tips – .NET News Daily Issue #174 (Apr 14, 2025)

Editor's note

I put together a deliberately mixed issue this time: architecture, platform updates, and a few deep technical walk-throughs. The NuGet Restore rewrite in .NET 9 is a great look at how the platform team tackles performance at scale, and the keyed DI piece is a practical one for anyone cleaning up service registration. There’s also some useful ASP.NET Core guidance on forwarded headers, which still trips people up in real deployments.

ASP.NET Core middleware, DI, and perf tips

Rise and shine, code warriors! This Monday, we're shifting into high gear, like a trusty classic car, polished and ready to tackle the road ahead. As you sip your coffee and get ready to navigate the bustling lanes of .NET development, remember that each article in today's lineup is a turbo-charged engine waiting to speed up your coding prowess. So, fasten your seatbelt and let's breeze through some top-tier insights to kick off a productive week!

Today's Articles

Return Streams Better in .NET: A Senior Engineer’s Perspective

https://medium.com/c-sharp-programming/return-streams-better-in-net-a-senior-engineers-perspective-e99ada7a5932

The Early History of Dealing with Data in .NET Continue reading on .Net Programming »

Article preview

Design Patterns in C#: Advanced Examples and Real-World Use Cases

https://medium.com/@orbens/design-patterns-in-c-advanced-examples-and-real-world-use-cases-6073a0d3fd61?source=rss------csharp-5

Introduction:

Article preview

Blockchain-Based Logging

https://ahmadminoo.medium.com/blockchain-based-logging-6f29d89f8976

Creating a blockchain for application logs is a clever way to ensure tamper-proof audit trails, immutability, and integrity of logs. This…

Article preview

Announcing Hybrid Search with Semantic Kernel for .NET

https://devblogs.microsoft.com/semantic-kernel/announcing-hybrid-search-with-semantic-kernel-for-net/

Today we’re thrilled to announce support for Hybrid search with Semantic Kernel Vector Stores for .NET. What is Hybrid Search? Hybrid search performs two parallel searches on a vector database. The u...

Article preview

If you’ve spent enough time in .NET

https://medium.com/@riturajpokhriyal/if-youve-spent-enough-time-in-net-5218ed1ae707

Understanding Value Types and Reference Types

Article preview

Understanding the Dependency Inversion Principle (DIP) in SOLID Design

https://www.c-sharpcorner.com/article/understanding-the-dependency-inversion-principle-dip-in-solid-design/

The Dependency Inversion Principle (DIP) promotes decoupling by ensuring high-level modules depend on abstractions, not concrete implementations, enhancing flexibility, testability, and maintainabilit...

Article preview

.NET 8 - System.Linq.Dynamic.Core – using SQL LIKE

https://www.c-sharpcorner.com/article/net-8-system-linq-dynamic-core-using-sql-like/

System.Linq.Dynamic.Core library does not support SQL LIKE, and I added support for it. Added SQL LIKE support to the System.Linq.Dynamic.Core in .NET 8 using a custom patch. Enables dynamic SQL patte...

Article preview

Configuring ASP.NET Core Forwarded Headers Middleware

https://nestenius.se/net/configuring-asp-net-core-forwarded-headers-middleware/

In my previous blog post, I explained what the Forwarded Headers Middleware does and why it matters. In this post, I will show you how to add it to your application, configure it, and point out a few ...

Article preview

Stop Overwriting Your Services: The Case for Keyed DI in .NET 8

https://www.c-sharpcorner.com/article/stop-overwriting-your-services-the-case-for-keyed-di-in-net-8/

Avoid service conflicts and boost flexibility with .NET 8’s Keyed Dependency Injection—supporting multiple implementations of the same interface.

Article preview

Still Using Async Like This? 5 Mistakes That Hurt Performance

https://itnext.io/still-using-async-like-this-5-mistakes-that-hurt-performance-0cc1778a8a02

Stop crashing your threads — optimize async the right way. Continue reading on ITNEXT »

Article preview

Software Architect’s Vision on .NET 9

https://medium.com/@Adem_Korkmaz/software-architects-vision-on-net-9-20ee4c53e570

The future is fast, modular, and cloud-optimized. And we’re building it

Article preview

How we ended up rewriting NuGet Restore in .NET 9

https://devblogs.microsoft.com/dotnet/rewriting-nuget-restore-in-dotnet-9/

Learn about the journey that led to a full rewrite of the NuGet Restore algorithm in .NET 9, achieving break-through scale and performance.

Article preview

Linear Search

https://medium.com/@johnson732j/linear-search-4845f5a94365

Starting with the simple search Algorithm

Article preview

The Dark Side of C#: Common Pitfalls Even Senior Developers Fall Into

https://medium.com/@nagarajvela/the-dark-side-of-c-common-pitfalls-even-senior-developers-fall-into-2a2cebff1e40

Uncover subtle C# bugs with fixes for async void, collections, dates, and leaks — plus a real-world lesson. Continue reading on Towards Dev »

Article preview

Real-Time Video Chat with .NET & Blazor: A Full-Stack Developer’s Guide

https://medium.com/asp-dotnet/real-time-video-chat-with-net-blazor-a-full-stack-developers-guide-4c2d69c5b66d

We Try to find how to build a high-performance, real-time video chat application using .NET and Blazor — leveraging WebRTC for… Continue reading on ASP DOTNET »

Article preview

Unlock C# Performance: Deep Dive into Ref Structs with Detailed Examples

https://medium.com/@shamuddin/unlock-c-performance-deep-dive-into-ref-structs-with-detailed-examples-da8c267a6bd4

In today’s performance-critical applications, managing memory efficiently is a top priority. C# provides an advanced feature known as ref…

Article preview

Jasen's take on today's picks

Return Streams Better in .NET: A Senior Engineer’s Perspective

Great practical advice on streaming APIs and where returning streams can make your code better or worse.

Design Patterns in C#: Advanced Examples and Real-World Use Cases

Solid pattern examples with enough real-world framing to be worth a skim even if you know the classics.

Blockchain-Based Logging

Interesting idea for tamper-evident logging, though the real-world tradeoffs will matter a lot here.

Announcing Hybrid Search with Semantic Kernel for .NET

Semantic Kernel keeps growing into a more useful app layer for retrieval and search scenarios.

If you’ve spent enough time in .NET

A good reminder that long-time .NET habits can become invisible until they bite you.

Understanding the Dependency Inversion Principle (DIP) in SOLID Design

DIP is one of those principles worth revisiting when code starts getting hard to swap or test.

.NET 8 - System.Linq.Dynamic.Core – using SQL LIKE

The SQL LIKE angle with Dynamic LINQ is niche, but it’s the kind of thing people actually need.

Configuring ASP.NET Core Forwarded Headers Middleware

Forwarded headers are simple on paper and easy to misconfigure in front of proxies and load balancers.

Stop Overwriting Your Services: The Case for Keyed DI in .NET 8

Keyed DI is a nice addition when multiple implementations start crowding the same service contract.

Still Using Async Like This? 5 Mistakes That Hurt Performance

Async mistakes still show up in production code, and performance costs add up fast.

Software Architect’s Vision on .NET 9

Worth reading for the platform perspective alone, especially if you care where .NET 9 is headed.

How we ended up rewriting NuGet Restore in .NET 9

The NuGet Restore rewrite is a rare behind-the-scenes look at a high-impact engineering effort.

Linear Search

A basic algorithm refresher, but sometimes that’s exactly the right thing in a varied lineup.

The Dark Side of C#: Common Pitfalls Even Senior Developers Fall Into

Senior developers still fall into the same traps; the difference is usually scale, not awareness.

Real-Time Video Chat with .NET & Blazor: A Full-Stack Developer’s Guide

Blazor plus real-time video chat is a good example of how far the stack can stretch.

Unlock C# Performance: Deep Dive into Ref Structs with Detailed Examples

Ref structs are powerful, but this is the kind of performance topic you want to approach carefully.

Related issues

📬 Get daily .NET content delivered to your inbox