-
Notifications
You must be signed in to change notification settings - Fork 143
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
Passing a cancellation token for subscription handlers, possible? #407
Comments
You can pass it directly in the method:
Because if you'd expect it to be provided via |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello. Hopefully this is just a simple question.
As a quick background, the canonical example for receiving messages is:
Now consider a handler where a potentially long, async operation is executed. It would be nice to pass a cancellation token to such operation. Something like this:
Is this currently possible with some enricher? Or, do I need custom middleware? I checked the default HandlerInvocationMiddleware (relevant call pasted below) and it does not pass the cancellation token to the handler.
The text was updated successfully, but these errors were encountered: