TCP和HTTP? [英] TCP and HTTP?

查看:61
本文介绍了TCP和HTTP?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不知道什么时候使用这两种方法.人们总是说-"...可以通过TCP或HTTP传输...."为什么TCP和HTTP之间存在或"?我了解,HTTP内部依赖TCP进行传输.

1.什么时候使用TCP或HTTP?
2.什么额外的HTTP可以做哪些TCP不能做呢?
3.谁能指出一个很好的图形表示形式,其中描述了TCP和HTTP的用法. (很抱歉,我的问题很愚蠢)

谢谢.

I never understand when to use either of these. People always talk that - "...can be transferred over TCP or HTTP...." why there is "Or" in between TCP and HTTP? i understand, HTTP internally rely on TCP for transporting.

1. When to use TCP or HTTP?
2. What extra HTTP can do which TCP does not?
3. Can anybody point me to a nice pictorial representation where the usage of TCP and HTTP depicted. (sorry for my dumb questions)

Thanks.

推荐答案

您无法真正比​​较它们.在协议栈中,HTTP会高于TCP/IP
假设HTTP正在将TCP/IP用于其transpor协议.

HTTP通常与TCP/IP一起用作其传输协议,但TCP/IP却没有不是必需的.


TCP/IP可以可靠地传输字节流,仅此而已.

HTTP是一种请求/答复协议,通常使用TCP/IP在客户端和服务器之间传输
数据.


您可能需要进行一些研究-我敢打赌,这是网络上记录最广的两个协议.

HTTP [ TCP/IP [ ^ ]

You can''t really compare them. In a protocol stack, HTTP would be above TCP/IP
assuming HTTP is using TCP/IP for its transpor protocol.

HTTP is often used with TCP/IP as its transport protocol but TCP/IP isn''t required.


TCP/IP provides reliable transfer of a stream of bytes, and that''s all.

HTTP is a request/reply protocol, often implemented using TCP/IP to transfer
data between clients and servers.


You could probably do a little research - I bet these are two of the most documented
protocols on the web...

HTTP[^]
TCP/IP[^]


这篇关于TCP和HTTP?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆