Development With A Dot

Blog on development in general, and specifically on .NET

Browse by Tags

All Tags » WCF (RSS)
.NET Serializers
(UPDATED) As of version 3.5 SP1, .NET comes along with the following serializers: System.Runtime.Serialization.Formatters.Binary.BinaryFormatte r : binary serializer used in .NET Remoting, type information is included, understands System.Runtime.Serialization...
Circular References in WCF
Updated: thanks to Nobody for the remark! Suppose you want to transmit a list of items where possibly some of them refer to other items on the list. For example: [DataContract] public class MenuItem { [DataMember] public String Text { get; set; } [DataMember...
Posted: May 18 2009, 07:55 PM by Ricardo Peres | with 1 comment(s)
Filed under: ,
Using MTOM with WCF
Suppose you want to transmit large binary contents (a file, for example) through WCF. In the usual way, you would use a classe decorated with a [DataContract] attribute, and you would have inside of it a property of type Byte[] , marked with a [DataMember...
Posted: May 14 2009, 10:39 AM by Ricardo Peres | with 3 comment(s)
Filed under: ,
Interface Inheritance
I am normally against having an interface inherit from another one, but there's a situation where I am in favor of it: web service interfaces! The reason is that we can write code like this: using ( ChannelFactory < IMyService > factory = new ChannelFactory...
Posted: Mar 17 2009, 08:18 PM by Ricardo Peres | with no comments
Filed under: ,
Setting Custom Identity in WCF
WCF was designed to be fully extensible, at all levels. If I want to pass a custom identity (an application-defined username and role and the desired culture) to a WCF web service (not using ASP.NET compatibility mode), this is what I do: I defined a...
Posted: Mar 13 2009, 05:20 PM by Ricardo Peres | with no comments
Filed under: ,
Validation of WCF Requests with the Enterprise Library Validation Block
In order to enable validation of the properties of a request message, you only need to add a [ValidationBehavior] attribute to your service interface, just next (or before) the [ServiceContract ], and a [FaultContract(typeof(ValidationFault ))] on the...
.NET StockTrader 2.03 Sample Application Released
Version 2.03 of the .NET StockTrader sample application was released. Key features are: The new download includes the automated setup for the .NET StockTrader 2.03 and the Configuration Service 2.03, with associated technical documents that explain how...
More Posts