mattisonchao commented on code in PR #15281:
URL: https://github.com/apache/pulsar/pull/15281#discussion_r858258840


##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/BrokersBase.java:
##########
@@ -286,16 +295,17 @@ public InternalConfigurationData 
getInternalConfigurationData() {
             @ApiResponse(code = 403, message = "Don't have admin permission"),
             @ApiResponse(code = 500, message = "Internal server error")})
     public void backlogQuotaCheck(@Suspended AsyncResponse asyncResponse) {
-        validateSuperUserAccess();
-        
pulsar().getBrokerService().getBacklogQuotaChecker().execute(safeRun(()->{
-            try {
-                pulsar().getBrokerService().monitorBacklogQuota();
-                asyncResponse.resume(Response.noContent().build());
-            } catch (Exception e) {
-                LOG.error("trigger backlogQuotaCheck fail", e);
-                asyncResponse.resume(new RestException(e));
-            }
-        }));
+        validateSuperUserAccessAsync()
+                .thenAcceptAsync(__ -> {
+                    pulsar().getBrokerService().monitorBacklogQuota();
+                    LOG.info("[{}] Successfully to trigger backlog quota 
check.", clientAppId());

Review Comment:
   The log is needed here because this is an action that needs to remind the 
user whether the operation was successful.



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