Dependency injection · interview question
Which service lifetime gives one instance per HTTP request in ASP.NET Core?
Multiple choiceEasy
Answer and explanation
Correct answer
A. Scoped
Why
ASP.NET Core creates a DI scope per request, so scoped services such as DbContext are shared within a request and disposed at its end.
Test yourself on Dependency injection
A free test with instant, explained results. No account needed.