DatanodeAdminDefaultMonitor (Apache Hadoop HDFS 3.5.0 API)
Description: declaration: package: org.apache.hadoop.hdfs.server.blockmanagement, class: DatanodeAdminDefaultMonitor

Package org.apache.hadoop.hdfs.server.blockmanagement

# Class DatanodeAdminDefaultMonitor

java.lang.Object
org.apache.hadoop.hdfs.server.blockmanagement.DatanodeAdminMonitorBase
org.apache.hadoop.hdfs.server.blockmanagement.DatanodeAdminDefaultMonitor

All Implemented Interfaces:
  `Runnable`, `org.apache.hadoop.conf.Configurable`, `DatanodeAdminMonitorInterface`

public class DatanodeAdminDefaultMonitor extends DatanodeAdminMonitorBase implements DatanodeAdminMonitorInterface
Checks to see if datanodes have finished DECOMMISSION_INPROGRESS or ENTERING_MAINTENANCE state.

Since this is done while holding the namesystem lock, the amount of work per monitor tick is limited.

- ## Field Summary

  ### Fields inherited from class org.apache.hadoop.hdfs.server.blockmanagement.DatanodeAdminMonitorBase

  `blockManager, conf, dnAdmin, maxConcurrentTrackedNodes, namesystem`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `getBlocksPerLock()`
  `int`
  `getNumNodesChecked()`
  `int`
  `getPendingRepLimit()`
  `int`
  `getTrackedNodeCount()`
  `protected void`
  `processConf()`
  Abstract method which must be implemented by the sub-classes to process set various instance variables from the Configuration passed at object creation time.
  `void`
  `run()`
  `void`
  `setBlocksPerLock(int blocksPerLock)`
  `void`
  `setPendingRepLimit(int pendingRepLimit)`
  `void`
  `stopTrackingNode(DatanodeDescriptor dn)`

  ### Methods inherited from class org.apache.hadoop.hdfs.server.blockmanagement.DatanodeAdminMonitorBase

  `getCancelledNodes, getConf, getPendingNodeCount, getPendingNodes, setBlockManager, setConf, setDatanodeAdminManager, setNameSystem, startTrackingNode`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

  ### Methods inherited from interface org.apache.hadoop.hdfs.server.blockmanagement.DatanodeAdminMonitorInterface

  `getCancelledNodes, getPendingNodeCount, getPendingNodes, setBlockManager, setDatanodeAdminManager, setNameSystem, startTrackingNode`

- ## Method Details

  - ### processConf

    protected void processConf()
    Description copied from class: `DatanodeAdminMonitorBase`
    Abstract method which must be implemented by the sub-classes to process set various instance variables from the Configuration passed at object creation time.
    Specified by:
      `processConf` in class `DatanodeAdminMonitorBase`

  - ### stopTrackingNode

    public void stopTrackingNode(DatanodeDescriptor dn)
    Specified by:
      `stopTrackingNode` in interface `DatanodeAdminMonitorInterface`

  - ### getTrackedNodeCount

    public int getTrackedNodeCount()
    Specified by:
      `getTrackedNodeCount` in interface `DatanodeAdminMonitorInterface`

  - ### getNumNodesChecked

    public int getNumNodesChecked()
    Specified by:
      `getNumNodesChecked` in interface `DatanodeAdminMonitorInterface`

  - ### getPendingRepLimit

    @VisibleForTesting public int getPendingRepLimit()
    Specified by:
      `getPendingRepLimit` in interface `DatanodeAdminMonitorInterface`

  - ### setPendingRepLimit

    public void setPendingRepLimit(int pendingRepLimit)
    Specified by:
      `setPendingRepLimit` in interface `DatanodeAdminMonitorInterface`

  - ### getBlocksPerLock

    @VisibleForTesting public int getBlocksPerLock()
    Specified by:
      `getBlocksPerLock` in interface `DatanodeAdminMonitorInterface`

  - ### setBlocksPerLock

    public void setBlocksPerLock(int blocksPerLock)
    Specified by:
      `setBlocksPerLock` in interface `DatanodeAdminMonitorInterface`

  - ### run

    public void run()
    Specified by:
      `run` in interface `Runnable`