HttpWatch的時間分析


HttpWatch的時間段捕捉詳解

這是一個IE的插件,下載可以 點這里。下載后解壓如下圖所示,一共有4個文件。HttpWatch

Professional是單獨軟件,可以單獨使用。

關於HttpWatch的時間段捕捉詳解 解壓后有四個文件

插件安裝時,只需運行httpwatchpro.exe,通常的安裝過程。然后打開瀏覽器,就可以看到已經安裝好的插件了。

關於HttpWatch的時間段捕捉詳解 插件安裝成功

​下面以百度為例來看TimeChart,詳解捕捉到的網頁的詳細各個響應時間。

關於HttpWatch的時間段捕捉詳解 httpwatch截取百度總圖
關於HttpWatch的時間段捕捉詳解 時間的具體項

選擇任意一條捕捉到的訪問步驟,來詳細學習時間軸的各個項的具體含義。

關於HttpWatch的時間段捕捉詳解 訪問網頁的時間軸示例

blocked:瀏覽器預處理時間(例如讀取本地緩存的時間)、等待網絡連接成功的時間。IE對一個主機名最多(例如www.baidu.com)可以同時創建2個網絡連接,對於其他的連接將進入排隊等待,直到其他連接完成。一般來說Blocked時間是網頁中對於圖片的下載時間最有意義的一個要素。

我們這里持續的是時間0.026秒。如果本地緩存比較多,那么這個部分的時間自然占用大。​

DNS
Lookup:
是把主機名轉換成IP地址的時間。在這個網頁被訪問的時候,一般DNS只會被解析一次。因為解析一次后,這個主機對應的IP地址將被緩存在本地。

Connect:表示連接的時間,是創建一個TCP連接到網絡服務器(或代理)。如果一個安全的HTTPS連接則包含SSL的握手時間。保持有效連接,經常用來避免過頻反復連接網絡服務器。

Send:從HTTP請求開始發送到請求發完的時間,這個時間長短依賴於發送到服務器的數據的多少。例如,若Send時間很長,是由於用HTTP
POST上傳文件所花費時間的結果。

Wait:是等待請求發送完到接收到服務器反饋的時間,相對比較准確的服務器的處理能力,但是不是絕對等於服務器響應時間。這個數值包括網絡的潛在時間、服務器的應答過程時間。

例如,我們可以比對,不同網站的Wait的時間,可以相對的了解,服務器的相應時間。​

Receive:從響應的第一個字節開始,到把響應接收完為止的時間。這個時間主要依賴於文本的大小,也依賴於網絡帶寬和是否有使用HTTP壓縮等。

 

兩個匯總時間:

1)TTFB
(or Time To First
Byte) 
從開始發送請求到接收到請求的時間。​

TTFB (or Time To First Byte)
是瀏覽器的初始化到從服務器接收到的第一個字節的時間。這個時間段是網絡的時間,主要包含了TCP連接的時間、發送請求的時間和從服務器接收到的第一個字節。

TTFB =Connect Send Wait

2)Network與網絡相關的HTTP請求時間,匯總時間

Network​=TTFB Receive​

 

 

 

Blocked time includes any pre-processing time (such as cache lookup) and the time spent waiting for a network connection to become available. Internet Explorer will only create a maximum of two concurrent network connections per host name (i.e. www.microsoft.com) and will queue up requests until a network connection is available. Often the Blocked time is the most significant factor in the download time of images embedded in a web page.

閉塞時間,包括所有的過程之前的時間(像,cache對比)和等待網絡鏈接的時間,IE在每個主機名(像www.microsoft.com)下最多只創建兩個當前的網絡連接,而且要排隊等待直到這個網絡鏈接可用,通常,閉塞時間影響網頁中圖片加載時間的重要因素。

Connect is the time required to create a TCP connection to the web server (or proxy). If a secure HTTPS connection is being used this time includes the SSL handshake process. Keep-Alive connections are often used to avoid the overhead of repeatedly connecting to the web server.

連接時間,是創建TCP連接到服務器或者代理服務器所花費的時間,如果一個包含SSL的安全的HTTPS連接存在,Keep-Alive鏈接經常被用到,以避免多次重復的連接WEB服務器。

Send is the time required to send the HTTP request message to the server and will depend on the amount of data that is sent to the server. For example, long Send times will result from uploading files using an HTTP POST

發送,是發送HTTP請求到服務器的時間,而且這個時間取決與發送請求的數據量的大小,例如,長的發送時間是由於用PSOT方式上傳文件造成的。

Wait is the idle time spent waiting for a response message from the server. This value includes delays introduced due to network latency and the time required to process the request on the web server.

等待,是花費在等待服務器響應消息的空閑時間,這個值包括網絡延遲和服務器處理請求的時間。

Receive is the time taken to read the response message from the server. This value will be depend on the size of the content returned, network bandwidth and whether HTTP compression was used.

接收,是花費在從服務器讀取響應消息的時間。這個值可以受到請求消息內容的大小,網絡帶寬和是否使用了HTTP壓縮。

Cache Read is the time taken to read the content from the browser cache during (Cache) or 304 responses.

緩存讀取,是花費在從瀏覽器緩存中讀取內容或者304響應的時間。

TTFB (or Time To First Byte) is the duration from the initial network request being initiated by the browser to the first byte being received from the server. It includes TCP connection time, the time to send the request and the time taken to get the first byte of the response message.

TTFB,是最初的網絡請求被發起到從服務器接收到第一個字節這段時間,它包含了TCP連接時間,發送HTTP請求時間和獲得響應消息第一個字節的時間。

Network is the total duration of all network related operations for an HTTP request.

Network,是所有的對一個HTTP請求的相關操作的這段時間。

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM