Thursday, February 25, 2021

System design: WebSockets | HTTP and Websockets: Understanding the capabilities of today’s web communication technologies

 Feb. 25, 2021

Introduction

It is so challenge for me to read articles, since I have to be patient and I am taking shortcuts to learn things by not doing it. I like to learn more about websockets in next few days. Reading is so efficient tool for me to acquire new skills. 

WebSockets 

Here is the link of article on medium.com. 

There are so many classifications for APIs. But when it comes to web communication, we can identify two significant API types — Web Service APIs (e.g. SOAP, JSON-RPC, XML-RPC, REST) and Websocket APIs. But, what do these really mean? Let’s dive into the world of web communication protocols and discuss how to choose the best API mechanisms at the end.

HTTP is the underlying communication protocol of the World Wide Web. HTTP functions as a request-response protocol in the client-server computing model. HTTP/1.1 is the most common version of HTTP used in modern web browsers and servers. In comparison to early versions of HTTP, this version could implement critical performance optimizations and feature enhancements such as persistent and pipelined connections, chunked transfers, new header fields in request/response body etc. Among them, the following two headers are very notable, because most of the modern improvements to HTTP rely on these two headers.

  • Keep-Alive header to set policies for long-lived communications between hosts (timeout period and maximum request count to handle per connection)
  • Upgrade header to switch the connection to an enhanced protocol mode such as HTTP/2.0 (h2,h2c) or Websockets (websocket)


No comments:

Post a Comment