In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
This article mainly explains "how to understand the HTTP protocol stateless". The content of the article is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn "how to understand the HTTP protocol stateless".
Http is a stateless protocol. Two consecutive requests in the same session do not know each other, and they are parsed by the newly instantiated environment, which does not store any information related to the session except for all the information that the application itself may have stored in the global object.
What is HTTP protocol stateless?
My own understanding, in asp.net: there is no relationship between the page submitted to the server each time, and the information recorded on the page will not be remembered the next time it is submitted (except for all the information that the application itself may have stored in the global object). Net is actually ViewState,ViewState is the basic unit for saving page information in asp.net, and when applied, it is the data stored in the hidden domain of the control.
The status of the protocol refers to the ability of the next transmission to remember this transmission.
Http will not maintain the information transmitted by this connection for the next connection.
Stateless means that when the browser sends a request to the server, the server responds, but when the same browser sends the request to the server, it responds, but he doesn't know that you are the browser just now, in short, the server will not remember you, so it is a stateless protocol.
DNS is a stateful protocol.
HTTP is an object-oriented protocol belonging to the application layer. HTTP protocol has five characteristics: 1, support client / server mode; 2, simple and fast; 3, flexible; 4, connectionless; 5, stateless; "stateless" is one of the main characteristics of HTTP protocol, the following is the explanation of "stateless". Stateless: refers to
The protocol has no memory ability for transaction processing. The lack of state means that if the previous information is required for subsequent processing, it must be retransmitted, which may result in an increase in the amount of data transmitted per connection. On the other hand, the server responds faster when it does not need previous information.
How to understand the stateless HTTP protocol
HTTP is an acronym for HyperTextTransferProtocol, and as its name implies, this protocol supports the transmission of hypertext. So what is hypertext? To put it bluntly, it is a page written in HTML. Typically, we use a client browser to access the server's resources, and the most common URL is a file with the suffix html. Therefore, we can say that hypertext is the most important resource on the Internet.
Since the purpose of the HTTP protocol is to support the transmission of hypertext and, more broadly, to support the transmission of resources, in the process that the client browser sends a request to the HTTP server, and then the HTTP server sends the corresponding resources back to the client, it is not necessary to record this process for both the client and the server, because each request and response are relatively independent. Just like you drop a coin in front of a vending machine to buy something, no one will or need to remember such a transaction process. Generally speaking, a URL corresponds to a unique hypertext, and the HTTP server is absolutely fair and fair, whether you are Michael or Jordon, it will return the same hypertext based on the received URL request. It is precisely because of this uniqueness that it becomes meaningless to record the behavior of users, so the HTTP protocol is designed as a stateless connection protocol to meet its own requirements.
Thank you for reading, the above is the content of "how to understand the statelessness of HTTP protocol". After the study of this article, I believe you have a deeper understanding of how to understand the statelessness of HTTP protocol, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.