Posts

Showing posts with the label WCF

Why ASMX-Style WebReferences to WCF Services Don’t serialize Numbers

  Based on a casual googling of this problem, it appears that some developers have spent days trying to figure out why an integer they set on the generated proxy field comes over the wire into the actual WCF service as ZERO.  I didn’t spend days figuring it out, but it certainly did cause no end of annoyance and cursing until I  did. Let’s say you have a WCF service and for one reason or another (maybe your app is on a Handheld device and you cannot use “Add Service Reference”) you’ve set an ASMX – style “Add Web Reference”.  Your code in the generated proxy Reference.cs class may look like this:   public int Quantity {             get {                 return this.quantityField;             }          ...

WSSF: Software Factories and You (or "Help, I've Fallen...")

"If it really were 1985 and you were writing Windows, you wouldn't even be doing it in C ... Windows itself was written in 8086 Assembly Language" -- Charles Petzold First - what's a Software Factory? In software engineering and enterprise software architecture, a software factory is defined as a software organization structured such that software projects are built in discrete "work centers". These generally represent, or specialize in, certain software disciplines such as architecture, design, construction, integration, test, maintenance, packaging, release, etc. Much like a true manufacturing facility, software factories require clearly defined product creation and management processes. By utilizing the same fundamentals as industrial manufacturing, a true Software Factory can achieve a superior level of application assembly even when assembling new or horizontal solutions. This can provide benefits in terms of economies of scale, geographic distributio...

WCF Service Debugging with the serviceDebug element.

Learning the "WCF way to do stuff" that you already know how to do is hard enough - but being able to debug boo-boos and fix them along the way can be an important part of your toolset. Since WCF services can return complete exception detail of a fault back over to the client, an easy way to enable this is to add the debug element: <behaviors> <serviceBehaviors> <behavior name="serviceBehavior" > <serviceDebug includeExceptionDetailInFaults="True" httpHelpPageEnabled="True"/> <serviceMetadata httpGetEnabled="true" /> </behavior> </serviceBehaviors> </behaviors> </system.serviceModel> the <serviceDebug element with the includeExceptionDetailInFaults and optional httpHelpPageEnabled attributes turns on this cool stuff for debugging. So if an exception occurs, it gets marshaled back to the client where you can see it. See here for details . Finally, Nicholas Allen has a wonderful dow...

D00D! Wake Up, .NET WCF is HERE, man!

Image
"There used to be a real me, but I had it surgically removed" -- Peter Sellers I confess I must have either been asleep at the switch, or Microsoft is just throwing so many CTP's and BETAs at us poor slobs that I got sensory overload. At any rate, WCF is here. They actually released it last November, according to Clemens Vasters , last Nov 8th - and its pre-baked into Windows Vista - all this under the moniker of ".NET Framework 3.0". Even some hosting ISP's have already installed it for their customers. OK, so what is WCF (Windows Communications Foundation) and why should I care, right? Let me try to provide a short, meaningful explanation: Do you think it would be useful to you as a programmer if they took ASP.NET Web Services, Web Service Enhancements, .NET Remoting, Enterprise Services, and System.Messaging, and rolled them all into this new integrated architecture, programming model, and runtime environment and provided a more productive SOA developmen...