Thread Pool Starvation, Cosmos DB and Local AI
Diagnose ASP.NET Core thread pool starvation with runtime tools, examine Cosmos DB transactions in preview, and call a local LLM from C#.
Jasen's top three picks
- 1 Finding Thread Pool Starvation in an ASP.NET Core Application
C# Corner
A practical diagnostic path for blocked requests: start with counters, then use stacks and traces to find the cause.
- 2 All or nothing: distributed transactions in Azure Cosmos DB
Microsoft Dev Blogs
Atomic writes across partition keys and containers are a notable change, but this capability is still in public preview.
- 3 Calling a Local LLM From C# Without Sending Data to a Cloud API
C# Corner
A useful starting point when an application needs LLM features without sending its data to a cloud API.
Editor's note
I’ve picked a varied mix of performance, data, security, and AI articles for this issue. The thread pool starvation guide is useful because it names the runtime tools that can help pinpoint blocking. I’m also watching Cosmos DB’s distributed transactions preview, which extends atomic writes across partition keys, containers, and databases.
Today's articles
Finding Thread Pool Starvation in an ASP.NET Core Application
C# Corner
Learn how Thread Pool starvation affects ASP.NET Core applications, which blocking patterns cause it, and how to diagnose it with dotnet-counters, dotnet-stack, and dotnet-trace.
Topics: ASP.NET Core Performance Profiling
Read articleAll or nothing: distributed transactions in Azure Cosmos DB
Microsoft Dev Blogs
Azure Cosmos DB for NoSQL can now commit writes across partition keys, containers, and databases as one atomic unit. Distributed transactions are currently in public preview. Every operation commits, ...
Read articleCalling a Local LLM From C# Without Sending Data to a Cloud API
C# Corner
Artificial intelligence is becoming a common feature in modern applications. Developers use large language models (LLMs) to generate text, summarize documents, answer questions, analyze data, and auto...
Topics: C#
Read articleASP.NET CustomErrors: Handling Application Errors Without Exposing Technical Details
Medium
Have you ever seen the default ASP.NET error page displayed to users after an unexpected exception?
Topics: .NET Framework Security
Read articleMentorAgent: Cut the Token Costs of Your .NET AI Agent
Medium
A chatbot sends a question and gets an answer. An agent that acts sends much more. Every call carries its instructions, the definition of…
Topics: C#
Read articleFinding slow requests with Aspire and an AI agent
Meziantou's blog
The previous posts in this series answered questions about one process at one moment: why it crashed, what it waits for, what holds its memory. "Which requests are slow?" is a different kind...
Topics: .NET Aspire Performance
Read article