本文整理匯總了Java中com.alibaba.cobar.manager.dataobject.cobarnode.CommandStatus.getPing方法的典型用法代碼示例。如果您正苦於以下問題:Java CommandStatus.getPing方法的具體用法?Java CommandStatus.getPing怎麽用?Java CommandStatus.getPing使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.alibaba.cobar.manager.dataobject.cobarnode.CommandStatus
的用法示例。
在下文中一共展示了CommandStatus.getPing方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: statistic
import com.alibaba.cobar.manager.dataobject.cobarnode.CommandStatus; //導入方法依賴的package包/類
public void statistic() {
initDBNum = 0;
queryNum = 0;
stmtPrepareNum = 0;
stmtExcuteNum = 0;
stmtClosed = 0;
pingNum = 0;
killNum = 0;
quitNum = 0;
otherNum = 0;
commandList = cobarAdapter.listCommandStatus();
for (CommandStatus command : commandList) {
initDBNum += command.getInitDB();
queryNum += command.getQuery();
stmtPrepareNum += command.getStmtPrepared();
stmtExcuteNum += command.getStmtExecute();
stmtClosed += command.getStmtClose();
pingNum += command.getPing();
killNum += command.getKill();
quitNum += command.getQuit();
otherNum += command.getOther();
}
}