예제 #1
0
    public Object visit(ExecutionEndEvent event) {
      final MutableExecutionInfo exec = executionMap.remove(event.executionId);
      if (exec == null) {
        return missing(event);
      }
      retiredExecutionMap.put(exec.executionId, exec);
      foo(exec, event);
      foo(exec.stmt.aggExec, event);
      foo(exec.stmt.conn.aggExec, event);
      foo(server.aggExec, event);

      // Since the execution info will no longer be in the table,
      // broadcast the final info to anyone who is interested.
      RolapUtil.MONITOR_LOGGER.debug(exec.fix());
      return null;
    }
예제 #2
0
 private void foo(MutableExecutionInfo exec, CellCacheSegmentDeleteEvent event) {
   ++exec.cellCacheSegmentDeleteCount;
   exec.cellCacheSegmentCoordinateSum -= event.coordinateCount;
   switch (event.source) {
     case EXTERNAL:
       ++exec.cellCacheSegmentDeleteViaExternalCount;
       break;
   }
 }
예제 #3
0
 private void foo(MutableExecutionInfo exec, CellCacheSegmentCreateEvent event) {
   ++exec.cellCacheSegmentCreateCount;
   exec.cellCacheSegmentCoordinateSum += event.coordinateCount;
   exec.cellCacheSegmentCellCount += event.actualCellCount;
   switch (event.source) {
     case ROLLUP:
       ++exec.cellCacheSegmentCreateViaRollupCount;
       break;
     case EXTERNAL:
       ++exec.cellCacheSegmentCreateViaExternalCount;
       break;
     case SQL:
       ++exec.cellCacheSegmentCreateViaSqlCount;
       break;
     default:
       throw Util.unexpected(event.source);
   }
 }
예제 #4
0
    private void foo(MutableExecutionInfo exec, ExecutionEndEvent event) {
      // NOTE: 'exec.phaseCount += event.phaseCount' would be wrong,
      // because we have already incremented each time we got an
      // ExecutionPhaseEvent. For a similar reason, we do not update
      // exec.cellCacheHitCount etc. each phase.

      ++exec.endCount;
      ++exec.phaseCount;
      exec.cellCacheHitCount += event.cellCacheHitCount;
      exec.cellCacheMissCount += event.cellCacheMissCount;
      exec.cellCachePendingCount += event.cellCachePendingCount;
      exec.cellCacheRequestCount +=
          (event.cellCacheHitCount + event.cellCacheMissCount + event.cellCachePendingCount);
      exec.cellCacheHitCountDelta = 0;
      exec.cellCacheMissCountDelta = 0;
      exec.cellCachePendingCountDelta = 0;
    }
예제 #5
0
 private void foo(MutableExecutionInfo exec, ExecutionPhaseEvent event) {
   ++exec.phaseCount;
   exec.cellCacheHitCountDelta = event.hitCount;
   exec.cellCacheMissCountDelta = event.missCount;
   exec.cellCachePendingCountDelta = event.pendingCount;
 }