umamaheswararao commented on code in PR #3504:
URL: https://github.com/apache/ozone/pull/3504#discussion_r898493158


##########
hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/hdds/scm/storage/TestContainerCommandsEC.java:
##########
@@ -278,6 +292,274 @@ public void testCreateRecoveryContainer() throws 
Exception {
     }
   }
 
+  private static byte[] getBytesWith(int singleDigitNumber, int total) {
+    StringBuilder builder = new StringBuilder(singleDigitNumber);
+    for (int i = 1; i <= total; i++) {
+      builder.append(singleDigitNumber);
+    }
+    return builder.toString().getBytes(UTF_8);
+  }
+
+  /**
+   * Tests the reconstruction of single missed data index.
+   */
+  @Test
+  public void testECReconstructionCoordinatorWithMissingIndexes1()
+      throws Exception {
+    testECReconstructionCoordinator(ImmutableList.of(1));
+  }
+
+  /**
+   * Tests the reconstruction of single missed data index.
+   */
+  @Test
+  public void testECReconstructionCoordinatorWithMissingIndexes2()
+      throws Exception {
+    testECReconstructionCoordinator(ImmutableList.of(2));
+  }
+
+  /**
+   * Tests the reconstruction of single missed data index.
+   */
+  @Test
+  public void testECReconstructionCoordinatorWithMissingIndexes3()
+      throws Exception {
+    testECReconstructionCoordinator(ImmutableList.of(3));
+  }
+
+  /**
+   * Tests the reconstruction of single missed parity index.
+   */
+  @Test
+  public void testECReconstructionCoordinatorWithMissingIndexes4()
+      throws Exception {
+    testECReconstructionCoordinator(ImmutableList.of(4));
+  }
+
+  /**
+   * Tests the reconstruction of single missed parity index.
+   */
+  @Test
+  public void testECReconstructionCoordinatorWithMissingIndexes5()
+      throws Exception {
+    testECReconstructionCoordinator(ImmutableList.of(5));
+  }
+
+  /**
+   * Tests the reconstruction of all missed parity indexes.
+   */
+  @Test
+  public void testECReconstructionCoordinatorWithMissingIndexes45()
+      throws Exception {
+    testECReconstructionCoordinator(ImmutableList.of(4, 5));
+  }
+
+  /**
+   * Tests the reconstruction of multiple data indexes missed.
+   */
+  @Test
+  public void testECReconstructionCoordinatorWithMissingIndexes23()
+      throws Exception {
+    testECReconstructionCoordinator(ImmutableList.of(2, 3));
+  }
+
+  /**
+   * Tests the reconstruction of data and parity missing indexes.
+   */
+  @Test
+  public void testECReconstructionCoordinatorWithMissingIndexes24()
+      throws Exception {
+    testECReconstructionCoordinator(ImmutableList.of(2, 4));
+  }
+
+  /**
+   * Tests the reconstruction of data and parity missing indexes.
+   */
+  @Test
+  public void testECReconstructionCoordinatorWithMissingIndexes35()
+      throws Exception {
+    testECReconstructionCoordinator(ImmutableList.of(3, 5));
+  }

Review Comment:
   Good suggestion. Thanks



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to