You are on page 1of 4

Introduction

In this article, I am describing what is Window Communication Foundation (WCF) and why
it is introduced in .NET Framework 3.0.

Background
In Modern Application (Distributed Application) development, you can use COM+, .NET
Enterprise Services, MSMQ, .NET Remoting, Web services, etc. for communication. All
these technologies play a different role and to use it you need to develop different solutions
for different technologies. You have to focus on each of the technologies to develop rather
than the application business logic.
WCF unifies the capabilities into single, common, general service oriented programming
model for Communication. WCF provides a common approach using a common API which
developers can focus on their application rather than on communication protocol.

Why Do We Need WCF?


There is one main Bank system which is directly connected with the database, that provides
other systems like ATM machine, Loan System data using various communication protocols
like Remoting, web service, etc. For communicating with different Systems using different
communication protocols, you have to know the API of that technology. In WCF, you have to
just make different End points for different services. There is no need to learn a different API.
You can use only one common API for communication with different System.

In WCF, you have to just make different End points for different services. There is no need to
learn a different API. You can use only one common API for communication with a different
System.

WCF Architecture

ABC of an EndPoint in WCF

All communications with the WCF service will happen via the endpoints. The endpoints
specify a Contract that defines which methods of the Service class that will be accessible
via the endpoint; each endpoint may expose a different set of methods. The endpoints also
define a binding that specifies how a client will communicate with the service and the address
where the endpoint is hosted.
A-Address(Where?): Specifies the location of the service which will be like
http://Myserver/MyService.Clients will use this location to communicate with our service.
Collapse | Copy Code
//
// The sample address for above transport schema may look like
http://localhost:81
http://localhost:81/MyService
net.tcp://localhost:82/MyService
net.pipe://localhost/MyPipeService
net.msmq://localhost/private/MyMsMqService
net.msmq://localhost/MyMsMqService
//

B-Binding-Address(How?): Specifies how the two parties will communicate in terms of


transport and encoding and protocols.

You might also like