@Override
  public void endSocketWrite(boolean sync, long start, long bytesWritten, long retries) {
    final long now = getTime();
    if (sync) {
      stats.incLong(syncSocketWritesInProgressId, -1);
      stats.incLong(syncSocketWritesId, 1);
      stats.incLong(syncSocketWriteBytesId, bytesWritten);
      if (enableClockStats) {
        stats.incLong(syncSocketWriteTimeId, now - start);
      }
    } else {
      stats.incLong(asyncSocketWritesInProgressId, -1);
      stats.incLong(asyncSocketWritesId, 1);
      if (retries != 0) {
        stats.incLong(asyncSocketWriteRetriesId, retries);
      }
      stats.incLong(asyncSocketWriteBytesId, bytesWritten);
      if (enableClockStats) {
        stats.incLong(asyncSocketWriteTimeId, now - start);
      }
    }
  }
Increments the total number of nanoseconds spent scheduling messages to be processed.
geode-core/src/main/java/org/apache/geode/distributed/internal/DistributionStats.java