-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Question about registering a behavior #1075
Comments
try separating MediatR configuration from the behavior registration. like this builder.Services.AddTransient(typeof(IPipelineBehavior<,>), typeof(UnhandledExceptionBehavior<,>)); |
I won't work, I had the same problem |
In order to register Generic behaviors you have to use |
泛型他没有提供注入,使用atuofac |
can you share your request? you should inherit from IAppRequest and your response should be BaseResponse. |
Here is my request and response. Please help me with the registration code for the behavior as I am unable to understand the correct code to register the behavior, as this is not an open behavior
|
There are 2 ways to solve this issue: 1 - Use
2 - If you want to use
and define your request like this:
|
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days. |
Discussed in #1074
Originally posted by bancroftway September 26, 2024
I have a question regarding correct way to register my behavior whose complete code is below.
I have tried this way, but the behavior does not get called:
The text was updated successfully, but these errors were encountered: