private synchronized void flush() {
      if (TOTAL.intValue() >= MAX_QUEUE) {
        mc.waitForQueues(5, TimeUnit.SECONDS);
        TOTAL.set(0);
      }
    }
Adaptation of http://code.google.com/p/spcached/wiki/benchmarktool.
src/test/manual/net/spy/memcached/test/MemcachedThreadBench.java