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

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

# Class NumberReplicas

java.lang.Object
org.apache.hadoop.hdfs.util.EnumCounters<NumberReplicas.StoredReplicaState>
org.apache.hadoop.hdfs.server.blockmanagement.NumberReplicas

public class NumberReplicas extends EnumCounters<NumberReplicas.StoredReplicaState>
A immutable object that stores the number of live replicas and the number of decommissioned Replicas.

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static enum`
  `NumberReplicas.StoredReplicaState`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `NumberReplicas()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `corruptReplicas()`
  `int`
  `decommissioned()`
  `int`
  `decommissionedAndDecommissioning()`
  `int`
  `decommissioning()`
  `int`
  `excessReplicas()`
  `int`
  `liveEnteringMaintenanceReplicas()`
  `int`
  `liveReplicas()`
  `int`
  `maintenanceNotForReadReplicas()`
  `int`
  `maintenanceReplicas()`
  `int`
  `outOfServiceReplicas()`
  `int`
  `readOnlyReplicas()`
  `int`
  `redundantInternalBlocks()`
  `int`
  `replicasOnStaleNodes()`

  ### Methods inherited from class org.apache.hadoop.hdfs.util.EnumCounters

  `add, add, allLessOrEqual, anyGreaterOrEqual, asArray, deepCopyEnumCounter, equals, get, hashCode, negation, reset, reset, set, set, subtract, subtract, sum, toString`

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

  `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### NumberReplicas

    public NumberReplicas()

- ## Method Details

  - ### liveReplicas

    public int liveReplicas()

  - ### readOnlyReplicas

    public int readOnlyReplicas()

  - ### decommissionedAndDecommissioning

    public int decommissionedAndDecommissioning()
    Returns:
      decommissioned and decommissioning replicas

  - ### decommissioned

    public int decommissioned()
    Returns:
      decommissioned replicas only

  - ### decommissioning

    public int decommissioning()
    Returns:
      decommissioning replicas only

  - ### corruptReplicas

    public int corruptReplicas()

  - ### excessReplicas

    public int excessReplicas()

  - ### replicasOnStaleNodes

    public int replicasOnStaleNodes()
    Returns:
      the number of replicas which are on stale nodes. This is not mutually exclusive with the other counts -- ie a replica may count as both "live" and "stale".

  - ### redundantInternalBlocks

    public int redundantInternalBlocks()

  - ### maintenanceNotForReadReplicas

    public int maintenanceNotForReadReplicas()

  - ### maintenanceReplicas

    public int maintenanceReplicas()

  - ### outOfServiceReplicas

    public int outOfServiceReplicas()

  - ### liveEnteringMaintenanceReplicas

    public int liveEnteringMaintenanceReplicas()