Post #2870566
2025-04-03 13:58 UTC
Replies (1)
-
@crashtestdev@woof.tech 2025-04-03 15:25
@maxitb@mastodon.social that only works if you can manage access to your resources, MedtiatR doesn't have any ability to do that, it just resolves handlers (often, very slowly) and uses dependency injection to inject any resources, no different from injecting them straight into your controllers but with the added delay of MediatR resolving the correct handler And moving away from MediatR specifically, most resources dotnet devs will ever interact with will already be controlled by a query/command handler, like in the case of databases, that's what the database engine/server is doing, and it's going to be better suited, optimised and battle hardened to handle and schedule queries than anything that could be slopped out in dotnet