Last post Dec 27, 2019 10:22 AM by Chan Leo
Dec 25, 2019 06:30 AM|Chan Leo|LINK
I have used MediatR in previous version of Asp.Net Core and it was working fine but now when i inject services.AddMediatR() it is not working. How can i fix the issue?
Dec 25, 2019 06:48 AM|PaulTheSmith|LINK
How can i fix the issue?
By providing a concise sample of code which reproduces your problem and explaining exactly what the problem is.
Dec 25, 2019 08:21 AM|Khuram.Shahzad|LINK
Mr Chan Leo,
In dot net core 3 MediatR is not integrated directly as it was in previous version so you have to use two packages
And in Startup file you have to use
in startup instead of
Dec 25, 2019 08:40 AM|Chan Leo|LINK
What version of MediatR you have used in Dot Net Core 3?
Dec 26, 2019 04:39 AM|Khuram.Shahzad|LINK
Dot Net Core 3.0 and MediatR 7.0.0
Dec 27, 2019 10:09 AM|Khuram.Shahzad|LINK
Does that solve your problem, do you need more help like sample code?
Dec 27, 2019 10:22 AM|Chan Leo|LINK
Yeah with some affords at last it works. New version is not working with parameter less constructor.