0

I'm having issues getting good Exception information when using Microsoft.Practices.Unity to load some classes dynamically.

The code is on a remote server and I'm using ELMAh to capture errors. I see the exceptions but the exception information stops at DynamicModule.ns.Wrapped_IMyClass_GUID.MyFunction().

I've pushed debug classes to the server so I see the line numbers up to that point but I can't get the line numbers for these dynamically loaded classes.

Is there a setting I'm missing somewhere that allows the real inner exception information to be displayed?

1 Answer 1

0

Unity includes all the chain of the errors in the InnerException, of each one. For example if you have a chain of dependency like this: Service1 dependes on Service2 depends on Service3

and, if Unity failed to instanciate Service3 due to a resolution error, you'll get a resolution failed exception of Service1 having an InnerException of type resolution failed exception of Service2 having an InnerExcepetion of type resolution failed exception of Service3.

1
  • My issue is with an exception inside Service 2 for example. I don't get debug information for Service 2 DLL. I ended up finding my bug by removing Unity for that one class call and I got the error info in the exception. Commented May 23, 2013 at 16:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.