Skip to content
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

MessageModule.HandleError should log an Error when it throws #2366

Closed
SimonCropp opened this issue Sep 10, 2014 · 8 comments
Closed

MessageModule.HandleError should log an Error when it throws #2366

SimonCropp opened this issue Sep 10, 2014 · 8 comments
Labels
Milestone

Comments

@SimonCropp
Copy link
Contributor

When HandleEndMessage or HandleBeginMessage throw an Error is logged

However when HandleError is called a Warn is logged.

@SimonCropp SimonCropp added the Bug label Sep 10, 2014
@SimonCropp SimonCropp added this to the 4.7.0 milestone Sep 10, 2014
SimonCropp added a commit that referenced this issue Sep 10, 2014
@johnsimons
Copy link
Member

I'm pretty sure this is by design, see 94c74fb

So we only log a error when the message is sent to the error queue.

@SimonCropp
Copy link
Contributor Author

this exception is not sent to the error queue

@johnsimons
Copy link
Member

this exception is not sent to the error queue

Yes that is correct, that happens later on

@SimonCropp
Copy link
Contributor Author

nope. only the exception from the handler is appended to the error queue headers. not the exception from the MessageModule.HandleError

@johnsimons
Copy link
Member

That is not nice 😞

So any exception in a messagemodule does not get added to the error message?

@johnsimons
Copy link
Member

Also, I'm getting confused because in your link above you are pointing to TransportReceiver but you are actually talking about message modules, is the link right?

@SimonCropp
Copy link
Contributor Author

the link is correct

here is a test to debug. https://github.com/Particular/NServiceBus/blob/removeStackTraceTweaks/src/NServiceBus.AcceptanceTests/ExceptionHandling/When_Module_Error_throws.cs although u may want to do it on master since that branch has moved on a little

@SimonCropp
Copy link
Contributor Author

fixed in d414f49

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants