Duansg commented on code in PR #4196:
URL: https://github.com/apache/hertzbeat/pull/4196#discussion_r3566391691


##########
hertzbeat-collector/hertzbeat-collector-collector/src/main/java/org/apache/hertzbeat/collector/dispatch/CommonDispatcher.java:
##########
@@ -182,6 +187,10 @@ private void monitorCollectTaskTimeout() {
                     log.error("[Collect Timeout]: \n{}", metricsData);
                     if (metricsData.getPriority() == 0) {
                         dispatchCollectData(metricsTime.timeout, 
metricsTime.getMetrics(), metricsData);
+                    } else {
+                        long delay = (long) metricsData.getPriority() * 
DELAY_PER_PRIORITY;

Review Comment:
   Isn't this delay unnecessary? The `monitorCollectTaskTimeout` method 
triggers serial execution.
   
   If a collection task times out or hangs, the fallback handling can cause the 
`worker pool` to accumulate usage. I think this is where we really need to 
implement backoff—what do you think?



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