类 RpcStatus
- java.lang.Object
-
- com.alibaba.dubbo.rpc.RpcStatus
-
public class RpcStatus extends Object
URL statistics. (API, Cached, ThreadSafe)
-
-
方法概要
所有方法 静态方法 实例方法 具体方法 修饰符和类型 方法 说明 static void
beginCount(URL url, String methodName)
static void
endCount(URL url, String methodName, long elapsed, boolean succeeded)
Object
get(String key)
get value.int
getActive()
get active.long
getAverageElapsed()
get average elapsed.long
getAverageTps()
Calculate average TPS (Transaction per second).int
getFailed()
get failed.long
getFailedAverageElapsed()
get failed average elapsed.long
getFailedElapsed()
get failed elapsed.long
getFailedMaxElapsed()
get failed max elapsed.long
getMaxElapsed()
get max elapsed.Semaphore
getSemaphore(int maxThreadNum)
Get the semaphore for thread number.static RpcStatus
getStatus(URL url)
static RpcStatus
getStatus(URL url, String methodName)
long
getSucceeded()
get succeeded.long
getSucceededAverageElapsed()
get succeeded average elapsed.long
getSucceededElapsed()
get succeeded elapsed.long
getSucceededMaxElapsed()
get succeeded max elapsed.long
getTotal()
get total.long
getTotalElapsed()
get total elapsed.static void
removeStatus(URL url)
static void
removeStatus(URL url, String methodName)
void
set(String key, Object value)
set value.
-
-
-
方法详细资料
-
removeStatus
public static void removeStatus(URL url)
- 参数:
url
-
-
getStatus
public static RpcStatus getStatus(URL url, String methodName)
- 参数:
url
-methodName
-- 返回:
- status
-
endCount
public static void endCount(URL url, String methodName, long elapsed, boolean succeeded)
- 参数:
url
-elapsed
-succeeded
-
-
getActive
public int getActive()
get active.- 返回:
- active
-
getTotal
public long getTotal()
get total.- 返回:
- total
-
getTotalElapsed
public long getTotalElapsed()
get total elapsed.- 返回:
- total elapsed
-
getAverageElapsed
public long getAverageElapsed()
get average elapsed.- 返回:
- average elapsed
-
getMaxElapsed
public long getMaxElapsed()
get max elapsed.- 返回:
- max elapsed
-
getFailed
public int getFailed()
get failed.- 返回:
- failed
-
getFailedElapsed
public long getFailedElapsed()
get failed elapsed.- 返回:
- failed elapsed
-
getFailedAverageElapsed
public long getFailedAverageElapsed()
get failed average elapsed.- 返回:
- failed average elapsed
-
getFailedMaxElapsed
public long getFailedMaxElapsed()
get failed max elapsed.- 返回:
- failed max elapsed
-
getSucceeded
public long getSucceeded()
get succeeded.- 返回:
- succeeded
-
getSucceededElapsed
public long getSucceededElapsed()
get succeeded elapsed.- 返回:
- succeeded elapsed
-
getSucceededAverageElapsed
public long getSucceededAverageElapsed()
get succeeded average elapsed.- 返回:
- succeeded average elapsed
-
getSucceededMaxElapsed
public long getSucceededMaxElapsed()
get succeeded max elapsed.- 返回:
- succeeded max elapsed.
-
getAverageTps
public long getAverageTps()
Calculate average TPS (Transaction per second).- 返回:
- tps
-
getSemaphore
public Semaphore getSemaphore(int maxThreadNum)
Get the semaphore for thread number. Semaphore's permits is decided byConstants.EXECUTES_KEY
- 参数:
maxThreadNum
- value ofConstants.EXECUTES_KEY
- 返回:
- thread number semaphore
-
-