.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
 
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
david stephan

Home >> Articles >> WCF >> Post New Resource Bookmark and Share   

 Subscribe to Articles

Basics of an EndPoint in WCF tutorial

Posted By:Dhananjay Kumar       Posted Date: April 08, 2010    Points: 25    Category: WCF    URL: http://www.dotnetspark.com  

Basics of an EndPoint in WCF Tutorial. This article is targeted to beginners in WCF. This is a absolute theoretical article. It will explain all theoretical concept of an EndPoint, Address and more in WCF
 

Objective:

This article is targeted to beginners in WCF. This is a absolute theoretical article.
  1. It will explain all theoretical concept of an EndPoint in WCF.
  2. It will explain Address in WCF
  3. It will explain Binding and where, which binding should be used.
  4. It will explain Contract.
ABC of Endpoint in WCF

The three elements constitute an endpoint starts with letters that makeup a mnemonic phrase

"ABC of Endpoints"

image1.gif


image2.gif

image3.gif

Address of an Endpoint(A)

image4.gif
  1. Address specifes where the service is residing.
  2. This is an URL( Uniform Resource Locator)
  3. Address URL identifies , location of the service.
  4. Address should folllow the Web Service Addressing(WS-Addressing) standard.

    image5.gif

    image6.gif
The Address depends on whether it is hosted in IIS or managed application or WAS. This also depends on BINDING being used.

Example of different type of Addresses

image7.gif

Binding of an Endpoint (B)

Binding says , how the service could be used. Binding specifies
  1. Which protocol to be used
  2. Which encoding to be used.
  3. What type of security requeiremnet to be used like SSL or SOAP message security.
System provided Bindings

basicHttpBinding
  1. This is interoperable binding.
  2. This is commonly used as replacement for earler web service based on ASMX.
  3. It supports HTTP & HTTPS protocols.
  4. It supports MTOM encoding.
  5. It supports text encoding.
wsHttpBinding
  1. This is a secure binding.
  2. This is interoperable binding.
  3. This uses SOAP over HTTP.
  4. This supports reliability over Internet.
  5. This supports transaction over Internet.
  6. This supports security over Internet.
  7. This supports HTTP/HTTPS proptcol
  8. This supports text and MTOM encoding.
  9. This is default binding provided by WCF.
wsDualHttpBinding
  1. This supports all the feature of wsHttpBinding.
  2. This is mainly used for DUPLEX SERVICE CONTRACTS.
  3. This supports bidirectional communication.
webHttpBinding
  1. This is a secure binding.
  2. This is a interoperable binding.
  3. It supports Http/Https protocol.
  4. It does not use SOAP message format.

    image8.gif
wsFederationHttpBinding
  1. This is a secure Binding.
  2. This is interoperable binding.
  3. This supports federated security
  4. This supports Https/Https protocols.
  5. This uses text/MTOM encoding.

    image9.gif
netTCPBinding
  1. This is a secure Binding.
  2. This could only be used if client is also a WCF machine.
  3. This is used to send Binary encoded SOAP message from one WCF computer to another.
  4. This uses TCP (Transimission Control Protocol)
  5. This supports reliability.
  6. This supports transaction,
  7. This supports security.
netNamedPipeBinding
  1. This is a secure Binding.
  2. This could be used over a single WCF computer.
  3. This sends Binary encoded SOAP message over named pipes.
netMSMQBinding
  1. This is a queued Binding.
  2. This uses Binary encoded SOAP message.
  3. This sends message over MSMQ.
  4. Here communication should occur between two computers.
netPeerTCPBinding
  1. This is a secure Binding.
  2. This uses TCP overe peeer to peer.
  3. Communication should occur between two or more computers.
msmqIntegrationBinding

image10.gif

basicHttpContextBinding

This Binding is same as of basicHttpBinding with more attributes , like below
  1. It supports HTTP cookies
  2. It eanble SOAP haeders to excahnge context.
  3. This binding is mainly used for Durable services.
netTCPContextBinding

This Binding is same as of netTCPBinding with more attributes , like below
  1. It eanble SOAP haeders to excahnge context.
  2. This binding is mainly used for Durable services.
wsHttpContextBinding

This Binding is same as of wsHttpBinding with more attributes , like below
  1. It eanble SOAP haeders to excahnge context.
  2. This binding is mainly used for Durable services.
Example :


  
  
  

  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  

Contract of and EndPoint (C)

image12.gif


  1. Contract should be an Interacfe
  2. Contract could be a class also but better approach is interface.
  3. In config file this is preceded by prpject name space name
 


 Subscribe to Articles

     

Further Readings:

Responses

No response found. Be the first to respond this post

Post Comment

You must Sign In To post reply
Find More Articles on C#, ASP.Net, Vb.Net, SQL Server and more Here

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend