prashantpogde commented on a change in pull request #1998:
URL: https://github.com/apache/ozone/pull/1998#discussion_r604580905



##########
File path: 
hadoop-hdds/common/src/main/java/org/apache/hadoop/ozone/upgrade/UpgradeFinalizer.java
##########
@@ -167,4 +190,22 @@ StatusAndMessages finalize(String upgradeClientID, T 
service)
   StatusAndMessages reportStatus(String upgradeClientId, boolean takeover)
       throws IOException;
 
+  /**
+   * Interface to inject arbitrary failures for stress testing.
+   * @param InjectTestFunction function that will be called
+   *        code execution reached injectTestFunctionAtThisPoint() location.
+   * @param pointIndex code execution point for a given thread.
+   */
+  void configureTestInjectionFunction(UpgradeTestInjectionPoints pointIndex,
+                                      Callable<Boolean> injectTestFunction);
+
+  /**
+   * Interface to inject error at a given point in an upgrade thread.
+   * @param pointIndex TestFunction Injection point in an upgrade thread.
+   * @return "true" if the calling thread should not continue with further
+   *          upgrade processing, "false" otherwise.
+   */
+  Boolean injectTestFunctionAtThisPoint(UpgradeTestInjectionPoints pointIndex)
+      throws Exception;

Review comment:
       yup




-- 
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.

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