Пример #1
0
 public Object visit(SqlStatementsCommand command) {
   List<SqlStatementInfo> list = new ArrayList<SqlStatementInfo>();
   for (MutableSqlStatementInfo info : sqlStatementMap.values()) {
     list.add(info.fix());
   }
   return list;
 }
Пример #2
0
    public Object visit(SqlStatementEndEvent event) {
      final MutableSqlStatementInfo sql = sqlStatementMap.remove(event.sqlStatementId);
      if (sql == null) {
        return missing(event);
      }
      foo(sql, event);
      foo(sql.stmt.aggSql, event);
      foo(server.aggSql, event);

      // Since the SQL statement info will no longer be in the table,
      // broadcast the final info to anyone who is interested.
      RolapUtil.MONITOR_LOGGER.debug(sql.fix());
      return null;
    }
Пример #3
0
 private void foo(MutableSqlStatementInfo sql, SqlStatementEndEvent event) {
   ++sql.endCount;
   sql.rowFetchCount += event.rowFetchCount;
 }
Пример #4
0
 private void foo(MutableSqlStatementInfo sql, SqlStatementExecuteEvent event) {
   ++sql.executeCount;
   sql.executeNanos += event.executeNanos;
 }
Пример #5
0
 private void foo(MutableSqlStatementInfo sql, SqlStatementStartEvent event) {
   ++sql.startCount;
   sql.cellRequestCount += event.cellRequestCount;
 }