Class InstrumentedReadLock

java.lang.Object
org.apache.hadoop.util.InstrumentedLock
org.apache.hadoop.util.InstrumentedReadLock
All Implemented Interfaces:
Lock

@Private @Unstable public class InstrumentedReadLock extends InstrumentedLock
This is a wrap class of a ReadLock. It extends the class InstrumentedLock, and can be used to track whether a specific read lock is being held for too long and log warnings if so. The logged warnings are throttled so that logs are not spammed.
  • Constructor Details

    • InstrumentedReadLock

      public InstrumentedReadLock(String name, org.slf4j.Logger logger, ReentrantReadWriteLock readWriteLock, long minLoggingGapMs, long lockWarningThresholdMs)
  • Method Details