In this article, we will focus on ABC of WCF which is the core of WCF service endpoints.
This is one of the most important interview question also.
What is ABC of WCF?
WCF service comes into existence with a valid Endpoint. An endpoint consists of 3 major components.
These components are generally refer as ABC in WCF Service.
- A- Address (Where)
- B- Binding (How)
- C- Contract (What)
An address is basically an URL which tells where exactly the service is hosted. We can also refer it as location of WCF service.
B for Binding and it describes that how a client will communicate with WCF service. WCF supports various protocols like HTTP, TCP, MSMQ, Named Pipes. Binding tells that what protocol will be used to communicate.
And C stands for Contract, which tells that what an endpoint will communicate and the client will be aware of the operations that were exposed. It is basically a contract between client and server which includes message content, message structure etc.
Below is the example of ABC in WCF.
<endpoint address="<Service URL>" contract="ITestService" binding="wsHttpBinding"/>
In next blog, I will wrote about various types of Bindings in WCF
Related blogs to WCF Service-
- Introduction to WCF
- ABC of WCF
- Basics of WCF Architecture
- WCF vs Web Service
- What is XML serialization?
- WCF Binding
- Create first WCF application
- Fault Contract in
- WCF Data Contract vs Message Contract
- Message Contract
- Data Contract Serialization and De-Serialization
- Data Contract in WCF
- Operation Contract in WCF
- Service Contract in WCF
- How to host a WCF service in IIS?
- WAS Hosting in WCF
- Self Hosting in WCF
- How to create WCF RESTful Service.