Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

transport protocol in WCF

Tags:

wcf

while learning WCF , I found WCF supports HTTP , TCP , Named Pipes and MSMQ as transport protocol.But, Http is application layer protocol and it uses TCP as tranport protocol. So, what does - Http as transport protocol in WCF - means , when it uses TCP as transport layer.

like image 756
user1426187 Avatar asked Aug 29 '12 13:08

user1426187


People also ask

What transport protocols are supported in WCF?

The transport channel is the bottom-most channel of the WCF stack. The protocols that are typically used in this channel are HTTP, TCP, MSMQ, and named pipes, but WCF allows application developers to use other transports as well, such as Simple Mail Transfer Protocol (SMTP) or File Transfer Protocol (FTP).

What is transport WCF?

The transport layer is at the lowest level of the channel stack. The main transports used in Windows Communication Foundation (WCF) are HTTP, HTTPS, TCP, and named pipes. The topics in this section discuss choosing among these transports, configuring the transport, and setting tuning properties.

What is TCP in WCF?

The WCF TCP transport is optimized for the scenario where both ends of the communication are using WCF. This binding is the fastest WCF binding for scenarios that involve communicating between different machines.


1 Answers

From a network stack perspective, other than TCP, all of the things you listed are application-layer protocols that communicate over TCP (at least, on any modern system).

As far as WCF is concerned, though, none of that matters. A "Transport protocol" in this sense is exactly what is says -- its a protocol for transporting information from endpoint to endpoint. In this sense, the transport protocol defines things like the internal structure of the message, the delivery mechanism, what extra features are available, etc. When you look at all of those aspects, the HTTP, HTTPS, MSMQ, and Named Pipes protocols are all different from each other. But under the hood, eventually they're all going to generate TCP packets. (You can build custom transports for WCF that use UDP but I don't think any of the built-in ones can do so.)

In this context, it might be more appropriate to call the TCP transport a "raw TCP" transport. It uses a custom, low-level binary message format that is unique to WCF, and has much lower overhead than any of the other transport protocols. Technically, that message format is an application protocol layered on top of TCP, but it has no name and is completely internal to WCF, so it is simply called "the TCP transport protocol."

like image 69
Michael Edenfield Avatar answered Sep 20 '22 16:09

Michael Edenfield