Class MetadataScanResult

java.lang.Object
org.apache.hadoop.ozone.container.ozoneimpl.MetadataScanResult
All Implemented Interfaces:
ScanResult
Direct Known Subclasses:
DataScanResult

public class MetadataScanResult extends Object implements ScanResult
Represents the result of a container metadata scan. A metadata scan only checks the existence of container metadata files and the checksum of the .container file. It does not check the data in the container and therefore will not generate a ContainerMerkleTree.
  • Constructor Details

  • Method Details

    • fromErrors

      public static MetadataScanResult fromErrors(List<ContainerScanError> errors)
      Constructs a metadata scan result whose health will be determined based on the presence of errors.
    • deleted

      public static MetadataScanResult deleted()
      Constructs a metadata scan result representing a container that was deleted during the scan.
    • isDeleted

      public boolean isDeleted()
      Specified by:
      isDeleted in interface ScanResult
    • hasErrors

      public boolean hasErrors()
      Specified by:
      hasErrors in interface ScanResult
    • getErrors

      public List<ContainerScanError> getErrors()
      Specified by:
      getErrors in interface ScanResult
    • toString

      public String toString()
      Overrides:
      toString in class Object
      Returns:
      A string representation of the first error in this result, or a string indicating the result is healthy.