EF Core Interceptors and Events: Audit Fields and Slow Query Logging
We fill CreatedAt and UpdatedAt automatically with a SaveChangesInterceptor, log queries over a threshold with a DbCommandInterceptor, and watch the change tracker live through SavingChanges and StateChanged events. We also see why nothing runs when you forget the async override.
5 Nov 2026
·
10 min
·
2