Master Programmer's Training: HTTP protocol vs. binary protocol

Source: Internet
Author: User

In the previous article, "Master Programmer's Training: TCP, message subcontracting and protocol design" discusses some of the topic of protocol design, here to add to the HTTP protocol and binary protocol comparison.

The HTTP protocol is a text protocol and a name-based protocol, from both sides.

Features of text Protocol vs binary Protocol text protocol:
Convenient for people
Easy to read, understand, debug, construct
Resolve complex, redundant, multi-
Need to consider character escapes

The features of the binary protocol:
Easy Machine

Features of the name-based vs position-basedname-based Protocol:
Agreement fields areidentify with name
Agreement fieldsindependent of Location
The Protocol field can be defaulted
New protocol fields are more convenient
Parsing complex
Need to consider character escapes

Features of the Position-based protocol:
Each protocol field ishave a specific location
The new protocol field needs to be well-managed by protocol versioning (ProtobufThis kind of is very good)
More efficient resolution



--------Split Line---------
1. Master Programmer's Practice: Introduction
2. Master Programmer's Training: a summary of the technical article
3. Master Programmer's Training: IP, DNS and CDN
4. Master Programmer's Training: TCP, message subcontracting and protocol design
6. Master Programmer's Training: CGI and fastcgi


Recommended Wecode Programmer Cloud Notes--for programmersOpen Source、Simple and efficientCloud notebook software, using Youdao cloud to do cloud storage.
★Syntax Highlighting"Currently supports a variety of parties such as C + +, C #, Pascal, Java, vb.net, XML, HTML, Python, and SQL.
★Cloud Storage"In addition to the local notebooks, the cloud storage features have been added, and the Youdao cloud notes are now used as cloud storage.
★Document Encryption"provides document encryption to ensure the security of sensitive documents.
★multiple Local notebooks"Support for multiple local notebooks enables you to create new local notebooks, open, compress, and back up local notebooks.
★article AttachmentTo add multiple attachments to each article, and to open attachments and export attachments in a temporary directory. Youdao cloud attachments are also stored in the cloud.

Master Programmer's Training: HTTP protocol vs. binary protocol

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.