NameNodeLayoutVersion.Feature (Apache Hadoop HDFS 3.5.0 API)
Description: declaration: package: org.apache.hadoop.hdfs.server.namenode, class: NameNodeLayoutVersion, enum: Feature

Package org.apache.hadoop.hdfs.server.namenode

# Enum Class NameNodeLayoutVersion.Feature

java.lang.Object
java.lang.Enum<NameNodeLayoutVersion.Feature>
org.apache.hadoop.hdfs.server.namenode.NameNodeLayoutVersion.Feature

All Implemented Interfaces:
  `Serializable`, `Comparable<NameNodeLayoutVersion.Feature>`, `Constable`, `LayoutVersion.LayoutFeature`

Enclosing class:
  NameNodeLayoutVersion

public static enum NameNodeLayoutVersion.Feature extends Enum<NameNodeLayoutVersion.Feature> implements LayoutVersion.LayoutFeature
Enums for features that change the layout version.
To add a new layout version:

- Define a new enum constant with a short enum name, the new layout version and description of the added feature.
- When adding a layout version with an ancestor that is not same as its immediate predecessor, use the constructor where a specific ancestor can be passed.
- Specify a minimum compatible layout version. The minimum compatible layout version is the earliest prior version to which a downgrade is possible after initiating rolling upgrade. If the feature cannot satisfy compatibility with any prior version, then set its minimum compatible layout version to itself to indicate that downgrade is impossible. Satisfying compatibility might require adding logic to the new feature to reject operations or handle them differently while rolling upgrade is in progress. In general, it's possible to satisfy compatibility for downgrade if the new feature just involves adding new edit log ops. Deeper structural changes, such as changing the way we place files in the metadata directories, might be incompatible. Feature implementations should strive for compatibility, because it's in the best interest of our users to support downgrade.

- ## Nested Class Summary

  ## Nested classes/interfaces inherited from class java.lang.Enum

  `Enum.EnumDesc<E extends Enum<E>>`

- ## Enum Constant Summary

  Enum Constants
  Enum Constant
  Description
  `APPEND_NEW_BLOCK`
  `BLOCK_STORAGE_POLICY`
  `CREATE_OVERWRITE`
  `EDITLOG_LENGTH`
  `ERASURE_CODING`
  `EXPANDED_STRING_TABLE`
  `NVDIMM_SUPPORT`
  `QUOTA_BY_STORAGE_TYPE`
  `ROLLING_UPGRADE`
  `SNAPSHOT_MODIFICATION_TIME`
  `TRUNCATE`
  `XATTRS`
  `XATTRS_NAMESPACE_EXT`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `LayoutVersion.FeatureInfo`
  `getInfo()`
  `static NameNodeLayoutVersion.Feature`
  `valueOf(String name)`
  Returns the enum constant of this class with the specified name.
  `static NameNodeLayoutVersion.Feature[]`
  `values()`
  Returns an array containing the constants of this enum class, in the order they are declared.

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

  `clone, compareTo, describeConstable, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf`

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

  `getClass, notify, notifyAll, wait, wait, wait`

- ## Enum Constant Details

  - ### ROLLING_UPGRADE

    public static final NameNodeLayoutVersion.Feature ROLLING_UPGRADE

  - ### EDITLOG_LENGTH

    public static final NameNodeLayoutVersion.Feature EDITLOG_LENGTH

  - ### XATTRS

    public static final NameNodeLayoutVersion.Feature XATTRS

  - ### CREATE_OVERWRITE

    public static final NameNodeLayoutVersion.Feature CREATE_OVERWRITE

  - ### XATTRS_NAMESPACE_EXT

    public static final NameNodeLayoutVersion.Feature XATTRS_NAMESPACE_EXT

  - ### BLOCK_STORAGE_POLICY

    public static final NameNodeLayoutVersion.Feature BLOCK_STORAGE_POLICY

  - ### TRUNCATE

    public static final NameNodeLayoutVersion.Feature TRUNCATE

  - ### APPEND_NEW_BLOCK

    public static final NameNodeLayoutVersion.Feature APPEND_NEW_BLOCK

  - ### QUOTA_BY_STORAGE_TYPE

    public static final NameNodeLayoutVersion.Feature QUOTA_BY_STORAGE_TYPE

  - ### ERASURE_CODING

    public static final NameNodeLayoutVersion.Feature ERASURE_CODING

  - ### EXPANDED_STRING_TABLE

    public static final NameNodeLayoutVersion.Feature EXPANDED_STRING_TABLE

  - ### SNAPSHOT_MODIFICATION_TIME

    public static final NameNodeLayoutVersion.Feature SNAPSHOT_MODIFICATION_TIME

  - ### NVDIMM_SUPPORT

    public static final NameNodeLayoutVersion.Feature NVDIMM_SUPPORT

- ## Method Details

  - ### values

    public static NameNodeLayoutVersion.Feature[] values()
    Returns an array containing the constants of this enum class, in the order they are declared.
    Returns:
      an array containing the constants of this enum class, in the order they are declared

  - ### valueOf

    public static NameNodeLayoutVersion.Feature valueOf(String name)
    Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
    Parameters:
      `name` - the name of the enum constant to be returned.
    Returns:
      the enum constant with the specified name
    Throws:
      `IllegalArgumentException` - if this enum class has no constant with the specified name
      `NullPointerException` - if the argument is null

  - ### getInfo

    public LayoutVersion.FeatureInfo getInfo()
    Specified by:
      `getInfo` in interface `LayoutVersion.LayoutFeature`