Sun Java System Web Proxy Server 4.0.7 版本說明

快取 PURGE 功能

Proxy Server 允許 PURGE 請求清除快取的 URL。如果成功清除了請求的 URL,伺服器會傳送 HTTP 狀態碼為 200 (正常) 的回應。如果未快取指定的 URL,則會傳送 404 (找不到) 回應。

在以下範例中,伺服器傳回值 200。

bash-2.03$ telnet localhost 8088
Trying 172.9.10.1...
Connected to localhost.
Escape character is '^]'.
PURGE http://foo.com/ HTTP/1.0

HTTP/1.1 200 OK
Server: Sun-Java-System-Web-Proxy-Server/4.0
Date: Fri, 26 Oct 2007 08:15:30 GMT
Connection: close

在以下範例中,伺服器傳回值 404。

Connection closed by foreign host.
bash-2.03$ telnet localhost 8088
Trying 172.9.10.1...
Connected to localhost.
Escape character is '^]'.
PURGE http://foo.com/ HTTP/1.0

HTTP/1.1 404 Not Found
Server: Sun-Java-System-Web-Proxy-Server/4.0
Date: Mon, 17 Sep 2007 10:13:28 GMT
Content-length: 96
Content-type: text/html
Connection: close