empiredan commented on code in PR #1074:
URL: https://github.com/apache/incubator-pegasus/pull/1074#discussion_r931105112


##########
src/rdsn/include/dsn/utility/metrics.h:
##########
@@ -168,6 +171,16 @@ class metric_entity : public ref_counter
 
     ~metric_entity();
 
+    // Close all "closeable" metrics owned by this entity.
+    //
+    // `async` is used to control if the close operations are asynchronous or 
not. It is set to
+    // true by default, which means all metrics owned by this entity will be 
closed asynchronously
+    // without waiting for the close operations to be finished.
+    //
+    // Otherwise, once `async` is set to false, close() will be blocked until 
the close operations
+    // are finished.
+    void close(bool async = true);

Review Comment:
   OK, we can use enum class instead.



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