Using custom FaultContract object containing System.Exception causes 'Add Service Reference' to fail - by Yuriy Kostenko

Status : 

 


1
0
Sign in
to vote
ID 776214 Comments
Status Closed Workarounds
Type Bug Repros 0
Opened 1/10/2013 3:44:33 AM
Access Restriction Public

Description

I just noticed something particular. I have an internal service which is published through basicHttpBinding for which metadata is enabled. I also included a mex endpoint for http. We use Visual Studio 2012 & C#.

Just recently we noticed that we were unable to succesfully add a service reference to this service in our other projects. All that it would generate was the first custom exception we included through a FaultContract (actually, there was only 1 type). if I'd add a simple web reference it would work correctly as well. Also, the WcfClient.exe had no problems either in loading the services. Just VS.NET add service reference wouldn't work.

In the service this exception inherits from Exception and is marked as serializable. That's all you're supposed to do, no?

Anyway, this had me baffled. If I remove the FaultContract for this custom exception everything works fine. I can add a service reference, no problem. But is there a way I can still have my custom exceptions? Is this a known problem?
Sign in to post a comment.
Posted by Microsoft on 4/26/2013 at 11:47 AM
Thanks for your feedback. This is a known limitation of WCF and at this point we have decided not to fix this considering the risk of fixing and introducing regression. We will continue to monitor customer hits on this and may increase priority based on it.
Posted by Microsoft on 1/10/2013 at 9:05 PM
Thanks for your feedback.

We are rerouting this issue to the appropriate group within the Visual Studio Product Team for triage and resolution. These specialized experts will follow-up with your issue.
Posted by Microsoft on 1/10/2013 at 3:54 AM
Thank you for your feedback, we are currently reviewing the issue you have submitted. If this issue is urgent, please contact support directly(http://support.microsoft.com)