Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Designs or reviews .NET solution architecture across modular monoliths, clean architecture, vertical slices, DDD, CQRS, and microservices.
Use this skill ↓82% 86%+5 ptsof test cases passed
Passed 19 of 22 test cases with the skill, and 18 of 22 without it.
An external consulting firm submitted a diagram for a new C# system architecture featuring 20 distinct services and event buses. How should engineering leadership validate whether this architecture is acceptable?
Validates that data ownership paths are explicit.
3 of 3 safety checks passed
This reference documents common architectural mistakes in .NET systems and how to avoid them. Examples use C# 12+ features including primary constructors.
Creating interfaces for every class, even when there is only one implementation and no testing or extension need.
// Anti-pattern: Interface for the sake of interface
public interface IOrderService
{
Task<Order> GetOrderAsync(Guid id);
}
public class OrderService(AppDbContext db) : IOrderService
{
public async Task<Order> GetOrderAsync(Guid id)
=> await db.Orders.FindAsync(id);
}
// Then injected as:
services.AddScoped<IOrderService, OrderService>();
Use interfaces when there is a real need: multiple implementations, testing seams, or abstraction over infrastructure.
// Better: Direct class when no abstraction is needed
public sealed class OrderService(AppDbContext db)
{
public async Task<Order?> GetOrderAsync(Guid id, CancellationToken ct = default)
=> await db.Orders.FindAsync([id], ct);
}
Next to this one in the catalogue, plus more from the same author.