Blog posts

2026

Testing ASP.NET Core Apps: xUnit and Integration Tests with WebApplicationFactory

4 minute read

Published:

This post covers the two testing layers most .NET teams rely on heavily: unit tests with xUnit and integration tests with WebApplicationFactory. Unit tests give you fast feedback on isolated logic. Integration tests prove that your application actually boots, routes requests, resolves dependencies, and returns the expected HTTP responses.

EF Core Performance: AsNoTracking, Compiled Queries, and Split Queries

5 minute read

Published:

This post covers some of the most useful EF Core performance techniques you will apply in read-heavy applications: disable tracking for read-only queries, project only the data you need, use compiled queries for hot paths, and understand when split queries help avoid large join explosions. Performance work starts with measurement, but these patterns are worth knowing early.

EF Core Fundamentals: DbContext, Migrations, Tracking, and Relationships

4 minute read

Published:

This post covers the pieces of Entity Framework Core you need before building real data-backed applications. The essential model is: your entities represent data, DbContext coordinates access to that data, migrations evolve the schema, and change tracking decides what EF Core will insert, update, or delete.

Authorization in ASP.NET Core: Policies, Roles, Claims, and Resource-Based Access

3 minute read

Published:

This post covers the part of security that decides what an authenticated user is allowed to do. In ASP.NET Core, authorization usually builds on roles, claims, named policies, and sometimes resource-specific checks performed in code. If authentication answers “who are you?”, authorization answers “may you do this?”.

Authentication Basics for .NET APIs: Cookies vs JWT vs OAuth2/OIDC

4 minute read

Published:

This post gives an overview of the most common authentication approaches you will see in .NET applications: cookies, JWT bearer tokens, and OAuth2/OIDC-based sign-in flows. The important thing is not memorizing every protocol detail. The important thing is understanding what each approach is for and when it fits.

Error Handling in ASP.NET Core: Middleware, Exception Filters, and ProblemDetails

5 minute read

Published:

This post covers how to handle failures in an ASP.NET Core API without leaking stack traces or returning random error shapes. The goal is not to prevent every exception. The goal is to catch failures at the right level, log them, and return a consistent response contract such as ProblemDetails.

Model Binding and Validation in ASP.NET Core: DataAnnotations and FluentValidation Basics

5 minute read

Published:

This post covers two important jobs the framework performs for you: model binding and validation. Model binding turns incoming HTTP data into .NET values. Validation checks whether those values satisfy your rules. If you understand where each responsibility begins and ends, your endpoints become much easier to reason about.

Building Your First Web API in .NET 8: Controllers, Minimal APIs, and Routing

5 minute read

Published:

This post shows how to build your first ASP.NET Core Web API and, more importantly, how to think about the choices you make along the way. The two main styles are controllers and minimal APIs, and both rely on the same routing system underneath. Once you understand those pieces, building new endpoints stops feeling mysterious.