szetszwo commented on code in PR #778:
URL: https://github.com/apache/ratis/pull/778#discussion_r1019862352


##########
ratis-metrics-api/src/main/java/org/apache/ratis/metrics/MetricRegistries.java:
##########
@@ -93,10 +93,20 @@ public static MetricRegistries global() {
    * Add hook to register reporter for the metricRegistry.
    *
    * @param reporterRegistration Consumer to create the reporter for the 
registry.
+   * @param stopReporter Consumer to stop the reporter for the registry.
    */
   public abstract void addReporterRegistration(Consumer<RatisMetricRegistry> 
reporterRegistration,
       Consumer<RatisMetricRegistry> stopReporter);
 
+  /**
+   * Remove hook of reporter for the metricRegistry.
+   *
+   * @param reporterRegistration Consumer to create the reporter for the 
registry.
+   * @param stopReporter Consumer to stop the reporter for the registry.
+   */
+  public abstract void 
removeReporterRegistration(Consumer<RatisMetricRegistry> reporterRegistration,
+                                               Consumer<RatisMetricRegistry> 
stopReporter);

Review Comment:
   Let's add a default implementation for compatibility.
   ```java
     public void removeReporterRegistration(Consumer<RatisMetricRegistry> 
reporterRegistration,
         Consumer<RatisMetricRegistry> stopReporter) {
     }
   ```



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

Reply via email to