I have a silverlight application that is in a stable (production) state running Csla 4.5.40. I am using the Factory Implementation (ObjectFactory).
I needed to make some changes today so I updated all NuGet packages on the application and all of it's libraries. This upgraded the application to 4.5.600. I only made one code change to handle DataPortalException.ErrorInfo is now HttpErrorInfo instead of WCFErrorInfo. This change isn't impacting my issue as a DataPortalException is never received.
After updating the NuGet packages however if there is an exception (any exception) in the DAL leads to the following exception in Silverlight:
Property load or set failed for property Message (Exception of type 'System.OutOfMemoryException' was thrown.) at Microsoft.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at Microsoft.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccess(Task task)
at Microsoft.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
I cannot figure out the cause. Even doing "throw new Exception("Test");" immediatly in the DAL fetch method leads to this. None of my code runs between exception being raised in the DAL and receiving the above exception in Silverlight. I am stumped. If there is a DAL exception in the version running Csla 4.5.40 I get a DataPortalException object as expected.
Thank you for your help.
Reverting back to v4.5.501 with no changes to our applications fixed the issue.
There is a bug in a new 4.5.600 version of CSLA. It is placed in the Source\Csla\Server\Hosts\HttpChannel\HttpErrorInfo.cs. There is a while statement in the constructor that turns into an endless loop when there is at least one InnerException in the WcfErrorInfo object received as a parameter.
We solved our problem by rebuilding Csla.dll with the HttpErrorInfo fixed.
Copyright (c) Marimer LLC