views:

171

answers:

1

I am using Enterprise Library 4.x for my exception handling logging (ASP.NET application).

Here is the EntLib method I am calling:

ExceptionPolicy.HandleException(ex, exceptionPolicy.ToString());

How can I add a bit more details to the exception, like current request url, current user name, etc.?

I know I could wrap it in my exception and setting original exception as inner exception but that just doesn't seem right.

A: 

To answer my own question: :)

It's not possible and the solution is actually quite simple: implement your own publisher!

And thats what I did. It's simple but I had to implement a lot more that just the publisher, due to the EntLib architecture but it wasn't difficult or time consuming, since everything is explained in the documentation that comes with the EntLib 4.x.

muerte