public class HttpTaskMetrics
extends java.lang.Object
构造器和说明 |
---|
HttpTaskMetrics() |
限定符和类型 | 方法和说明 |
---|---|
double |
calculateMD5STookTime()
获取请求 BODY MD5 计算耗时
|
double |
connectTookTime()
获取连接建立耗时
|
static HttpTaskMetrics |
createMetricsWithHost(java.lang.String host) |
double |
dnsLookupTookTime()
获取 DNS 请求耗时
|
double |
fullTaskTookTime()
获取任务整体耗时,包括计算 md5 时间、计算签名时间和 http 请求时间
|
java.net.InetAddress |
getConnectAddress() |
java.lang.String |
getDomainName()
获取服务器域名
|
java.util.List<java.net.InetAddress> |
getRemoteAddress()
获取服务器IP地址
|
int |
getRetryCount() |
double |
httpTaskFullTime()
获取 http 请求执行时间
|
boolean |
isClockSkewedRetry() |
HttpTaskMetrics |
merge(HttpTaskMetrics taskMetrics) |
void |
onDataReady()
数据准备完毕时的回调,你可以重载此方法,实现数据完毕后的回调
|
double |
readResponseBodyTookTime()
获取读取响应体耗时
|
double |
readResponseHeaderTookTime()
获取读取响应头部耗时
|
void |
recordConnectAddress(java.net.InetAddress address) |
long |
requestBodyByteCount() |
long |
responseBodyByteCount() |
double |
secureConnectTookTime()
获取 TLS 建立会话耗时
|
void |
setClockSkewedRetry(boolean clockSkewedRetry) |
void |
setDomainName(java.lang.String domainName) |
void |
setRetryCount(int retryCount) |
double |
signRequestTookTime()
获取签名计算耗时,包括获取密钥时间
|
java.lang.String |
toString()
Returns a string representation of the object.
|
double |
writeRequestBodyTookTime()
获取写请求头部耗时
|
double |
writeRequestHeaderTookTime()
获取写请求体耗时
|
public long requestBodyByteCount()
public long responseBodyByteCount()
public double httpTaskFullTime()
public double dnsLookupTookTime()
public double connectTookTime()
public double secureConnectTookTime()
public double calculateMD5STookTime()
public double signRequestTookTime()
public double readResponseHeaderTookTime()
public double readResponseBodyTookTime()
public double writeRequestBodyTookTime()
public double writeRequestHeaderTookTime()
public double fullTaskTookTime()
@Nullable public java.util.List<java.net.InetAddress> getRemoteAddress()
@Nullable public java.net.InetAddress getConnectAddress()
@Nullable public java.lang.String getDomainName()
public void setDomainName(@Nullable java.lang.String domainName)
public int getRetryCount()
public void setRetryCount(int retryCount)
public boolean isClockSkewedRetry()
public void setClockSkewedRetry(boolean clockSkewedRetry)
public static HttpTaskMetrics createMetricsWithHost(java.lang.String host)
public void recordConnectAddress(java.net.InetAddress address)
public void onDataReady()
public HttpTaskMetrics merge(HttpTaskMetrics taskMetrics)
public java.lang.String toString()
java.lang.Object
toString
method returns a string that
"textually represents" this object. The result should
be a concise but informative representation that is easy for a
person to read.
It is recommended that all subclasses override this method.
The toString
method for class Object
returns a string consisting of the name of the class of which the
object is an instance, the at-sign character `@
', and
the unsigned hexadecimal representation of the hash code of the
object. In other words, this method returns a string equal to the
value of:
getClass().getName() + '@' + Integer.toHexString(hashCode())
toString
在类中 java.lang.Object