public int doWork()
    {
        final long nowNs = nanoClock.nanoTime();
        trackTime(nowNs);

        int workCount = 0;
        workCount += processTimers(nowNs);
        if (!asyncClientCommandInFlight)
        {
            workCount += clientCommandAdapter.receive();
        }
        workCount += drainCommandQueue();
        workCount += trackStreamPositions(workCount, nowNs);
        workCount += nameResolver.doWork(cachedEpochClock.time());
        workCount += freeEndOfLifeResources(ctx.resourceFreeLimit());

        return workCount;
    }
@Test
    void shouldIncrementCounterOnConductorThresholdExceeded()
    {
        final AtomicCounter maxCycleTime = spySystemCounters.get(CONDUCTOR_MAX_CYCLE_TIME);
        final AtomicCounter thresholdExceeded = spySystemCounters.get(CONDUCTOR_CYCLE_TIME_THRESHOLD_EXCEEDED);

        driverConductor.doWork();
        nanoClock.advance(MILLISECONDS.toNanos(750));
        driverConductor.doWork();
        nanoClock.advance(MILLISECONDS.toNanos(1000));
        driverConductor.doWork();
        nanoClock.advance(MILLISECONDS.toNanos(500));
        driverConductor.doWork();
        nanoClock.advance(MILLISECONDS.toNanos(600));
        driverConductor.doWork();
        nanoClock.advance(MILLISECONDS.toNanos(601));
        driverConductor.doWork();

        assertEquals(SECONDS.toNanos(1), maxCycleTime.get());
        assertEquals(3, thresholdExceeded.get());
    }