Dotnetcs

Simply Blogging

Categories: .NET

EF Core's Silent Performance Bug: The GroupBy That Runs on the CLIENT

EF Core's Silent Performance Bug: The GroupBy That Runs on the CLIENT

Pramod Pramod

This LINQ ran perfectly on my machine. It passed code review. It shipped. And then, with real data, it quietly started pulling thousands of rows into memory on every page load. csharp.GroupBy(m => m.ThreadId) .Select(g => g.OrderByDescending(m => m.CreatedDate).First()) One line. Let me show you exactly why — and the two-line fix.

Read More
EF Core's Silent Performance Bug: The GroupBy That Runs on the CLIENT

EF Core's Silent Performance Bug: The GroupBy That Runs on the CLIENT

Pramod Pramod

This LINQ ran perfectly on my machine. It passed code review. It shipped. And then, with real data, it quietly started pulling thousands of rows into memory on every page load. csharp.GroupBy(m => m.ThreadId) .Select(g => g.OrderByDescending(m => m.CreatedDate).First()) One line. Let me show you exactly why — and the two-line fix.

Read More