Are HTTP keep-alive connections possible without content-length headers?
问题 I understand that in HTTP 1.0, the content of a response is terminated by closing the connection. In HTTP 1.1, keep-alive connections were introduced, enabling multiple requests and responses in a single TCP connection. When multiple messages are sent over the same connection, there needs to be a mechanism that defines where one message ends and the next message starts. By testing, I found out that this works when I set the content-length header in a response. By knowing the content length,