Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-13210

Fix the typo in MiniDFSCluster class

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Trivial
    • Resolution: Fixed
    • 3.0.0
    • 3.1.0
    • test
    • None
    • Reviewed

    Description

      There is a typo SimilatedFSDataset in MiniDFSCluster#injectBlocks.
      In line2748 and line2769:

      public void injectBlocks(int dataNodeIndex,
            Iterable<Block> blocksToInject, String bpid) throws IOException {
          if (dataNodeIndex < 0 || dataNodeIndex > dataNodes.size()) {
            throw new IndexOutOfBoundsException();
          }
          final DataNode dn = dataNodes.get(dataNodeIndex).datanode;
          final FsDatasetSpi<?> dataSet = DataNodeTestUtils.getFSDataset(dn);
          if (!(dataSet instanceof SimulatedFSDataset)) {
            throw new IOException("injectBlocks is valid only for SimilatedFSDataset");
          }
      ...
      }
      

      SimilatedFSDataset should be SimulatedFSDataset.

      Attachments

        1. HDFS-13210.001.patch
          1.0 kB
          fang zhenyi
        2. HDFS-13210.002.patch
          1 kB
          fang zhenyi
        3. HDFS-13210.003.patch
          1 kB
          fang zhenyi

        Activity

          People

            zhenyi fang zhenyi
            linyiqun Yiqun Lin
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: