@Override public void dropOffOperation(OperationExecution result) { // Scoreboard closed? if (!running) return; // Assign label to the operation execution if (timing.inRampUp(result.timeStarted)) result.setTraceLabel(TraceLabels.RAMP_UP_LABEL); else if (timing.inSteadyState(result.timeFinished)) result.setTraceLabel(TraceLabels.STEADY_STATE_TRACE_LABEL); else if (timing.inSteadyState(result.timeStarted)) result.setTraceLabel(TraceLabels.LATE_LABEL); else if (timing.inRampDown(result.timeStarted)) result.setTraceLabel(TraceLabels.RAMP_DOWN_LABEL); // Put all results into the dropoff queue long lockStart = System.currentTimeMillis(); synchronized (swapDropoffQueueLock) { // Calculate time required to acquire this lock long dropOffWaitTime = (System.currentTimeMillis() - lockStart); // Update internal dropoff statistics totalDropOffWaitTime += dropOffWaitTime; totalDropoffs++; maxDropOffWaitTime = Math.max(maxDropOffWaitTime, dropOffWaitTime); // Dropoff this operation execution dropOffQ.add(result); } }