Category Archives: WCF

Thread Throttling in IIS-hosted WCF (sync vs. async)

I’m in the midst of a BizTalk project where we’re load testing our solution. Our receive adapters are WCF-based and therefore tuning WCF is a critical aspect of the overall solution performance. I have gone through the same tuning times before in every WCF project. But I always was lazy documenting the information and ended up looking up the bits and pieces time and time again to refresh my memory. Now I decided to document this information in a post for myself and others.

However, I will not simply write the keys to adjust and leave it there. I will explain the reason we adjust these keys and what they really mean. So bear with me and follow along.

Continue reading

Understanding .NET and WCF Transactions

Strictly speaking, implementing transactions in .NET and WCF is easy: you use WCF attributes to control the service and operations behaviors, and you are done! Moreover, an easier task is to transaction-enable .NET applications. .NET provides you with the classes to do just that. If that is the case, then why a course about transactions? Well, that is because just like everything else in programming, you need to understand the architecture, the underground of whatever seems to be an easy task. Only then can you design solutions as opposed to only coding them. WCF transactions are built from ground up around .NET transactions. This is hardly surprising anyway, since WCF is a .NET technology. However, this sums up as follows: you need to understand how .NET does transactions in order to utilize them in WCF.

My Pluralsight course aims to make you truly understand transactions. It first lays down the architecture of transactions, and then demonstrates how this architecture is implemented in .NET and WCF.

http://pluralsight.com/training/Courses/TableOfContents/understanding-dotnet-wcf-transactions

Creating a SOAP/REST – based WCF Service with Custom Binding/Behaviors

Introduction
Ok, basically the title says it all. This post shows a WCF service with a method exposed both as a SOAP-based and REST-based endpoint. For the SOAP-based endpoint I found that there is no binding that satisfy my needs (yep, I am picky!) so I will create a custom binding – explaining what are custom bindings and what is the Channel layer in general.
Also In order to enable logging operations, I will create two custom behaviors – again explaining what are custom behaviors and what is the ServiceModel layer in general.

Continue reading

WCF MSMQ Transactions Explained – Part1

Introduction

Before starting, I advise you to read my detailed article about .NET transactions and WCF implementation for more in depth knowledge about how transactions work. However, you can still go through this post directly to get the required knowledge about WCF MSMQ transactions.
When working with MSMQ and WCF, you have two options for bindings: NetMsmqBinding and MsmqIntegrationBinding. Continue reading

WF 4.0 WorkflowServiceHost Custom Tracking

In previous two-part post (here and here) I showed how to add persistence to a workflow hosted via the WorkflowServiceHost. In this post I will do some modifications on the same example to add tracking support. Now since I am a good guy and would like to make your lives easier, I will repost the full code here instead of pointing out only the differences. Let’s roll…
Continue reading