private void recordInternal(double value, long timeMs, boolean checkQuotas) {
        this.lastRecordTime = timeMs;
        synchronized (this) {
            synchronized (metricLock()) {
                // increment all the stats
                for (StatAndConfig statAndConfig : this.stats) {
                    statAndConfig.stat.record(statAndConfig.config(), value, timeMs);
                }
            }
            if (checkQuotas)
                checkQuotas(timeMs);
        }
        for (Sensor parent : parents)
            parent.record(value, timeMs, checkQuotas);
    }
Record a value at a known time. This method is slightly faster than {@link #record(double)} since it will reuse
the time stamp.
@param value The value we are recording
@param timeMs The current POSIX time in milliseconds
@param checkQuotas Indicate if quota must be enforced or not
@throws QuotaViolationException if recording this value moves a metric beyond its configured maximum or minimum
        bound
clients/src/main/java/org/apache/kafka/common/metrics/Sensor.java