I am making a webserver with RTOS on a MCU.
The network library uses HTTP 1.0 and closes the TCP socket and re-listens after each request.
The web page I am serving has multiple .js files that it needs to load after the html has fully loaded.
Once the html content is sent, immediately afterwards the web browser sends a "GET /file.js HTTP/1.1" message. This message is then retransmitted 3 or 4 times with TCP Retransmission before the web server is finally able to handle it.
Question 1: Is this fast transmission due to the web browser still attempting HTTP 1.1 protocol of not closing the connection? The content status reply message from our server is HTTP 1.0, but the web browser keeps requesting GET with HTTP 1.1.
Question 2: Is there a way to tell the web browser to slow down so it doesn't congest the network with TCP Retransmissions?
Any suggestions are helpful.
question from:
https://stackoverflow.com/questions/66055413/http-1-1-get-requests-are-too-quick-for-server-to-respond-causing-tcp-retransmis 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…