[JavaEE] http protocol details, javaeehttp Protocol
Previous: http://www.cnblogs.com/taoshihan/p/5346731.html
HTTP Request
Request Line
GET/taoshihan/p/52.1631.html HTTP/1.1
Request Method-request resource name-the Protocol to be followed
(POST, GET, DELETE, PUT, HEAD, OPTIONS, TRACE)
GET generally requires no more than 1 k, and there is no size limit for POST transmission.
Request Header
Host: www.cnblogs.com
Host Name
Connection: keep-alive
Connection information
Pragma: no-cache
Cache-Control: no-cache
Accept: text/html, application/xhtml + xml, application/xml; q = 0.9, image/webp, */*; q = 0.8
Acceptable: file type
Upgrade-Insecure-Requests: 1
User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2454.101 Safari/537.36
Client Information
Referer: http://zzk.cnblogs.com/s? W = blog % 3 Ataoshihan % 20% E5 % 8D % 8F % E8 % AE
Source Address
Accept-Encoding: gzip, deflate, sdch
Acceptable encoding: Compression
Accept-Language: zh-CN, zh; q = 0.8
Acceptable language: Chinese
Response Header
HTTP/1.1 200 OK
Protocol version-status code
Date: Thu, 19 May 2016 03:47:48 GMT
Content-Type: text/html; charset = UTF-8
Returned content type and encoding
Transfer-Encoding: chunked
Data transmission mode: Block
Connection: keep-alive
Vary: Accept-Encoding
Cache-Control: private, max-age = 10
Indicates whether the browser is cached.
Expires: Thu, 19 May 2016 03:47:58 GMT
Notifies the browser to cache resources to a specified time point
Last-Modified: Thu, 19 May 2016 03:47:48 GMT
Implement Cache
X-UA-Compatible: IE = 10
Content-Encoding: gzip
Content Encoding: Compression
Status Code
200 ~ 299 successfully received
300 ~ 399 resource transfer 302 (redirection), 304 (using cache), 307
400 ~ 499 request Error 404 not found
500 ~ 599 Internal Server Error 500