You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@rocketmq.apache.org by GitBox <gi...@apache.org> on 2022/04/01 20:47:07 UTC

[GitHub] [rocketmq] dugenkui03 opened a new issue #4098: Optimized the algorithm of trace message send.

dugenkui03 opened a new issue #4098:
URL: https://github.com/apache/rocketmq/issues/4098


   **FEATURE REQUEST**
   
   #### algorithm before
   Take `batchSize` loop calls then submit request, set 5ms timeout for every loop;
   
   #### algorithm now
   Submit request after take `batchSize` loop calls or wait `maxWaitTime`;
   
   #### why better
   In an operation of 'submit request', the new algorithm will send more data if there isn't any data in `traceContextQueue` more than 5ms.
   
   
   #### describe in Chinese
   优化`AsyncTraceDispatcher` 中的 消息发送算法。
   
   之前的逻辑:轮询 batchSize 次获取数据,超过 5ms 则中断数据获取;
   
   当前的逻辑:当获取 batchSize 个数据、或者500ms后,进行一次发送请求-如果有数据的话,500ms是最长等待时间、有之前的逻辑 5ms*batch计算所得;
   
   优化的场景:在一个发送窗口中,如果有超过5ms间隔没有消息、会导致之前的算法存在没有获取到数据的轮询,则之前的算法会比当前的算法少发送数据。


-- 
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: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] dugenkui03 commented on issue #4098: Optimized the algorithm of trace message send.

Posted by GitBox <gi...@apache.org>.
dugenkui03 commented on issue #4098:
URL: https://github.com/apache/rocketmq/issues/4098#issuecomment-1086538203


   @dongeforever The or for this issue https://github.com/apache/rocketmq/pull/4099


-- 
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: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] dugenkui03 edited a comment on issue #4098: Optimized the algorithm of trace message send.

Posted by GitBox <gi...@apache.org>.
dugenkui03 edited a comment on issue #4098:
URL: https://github.com/apache/rocketmq/issues/4098#issuecomment-1086538203


   @dongeforever The pr for this issue https://github.com/apache/rocketmq/pull/4099


-- 
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: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] dongeforever commented on issue #4098: Optimized the algorithm of trace message send.

Posted by GitBox <gi...@apache.org>.
dongeforever commented on issue #4098:
URL: https://github.com/apache/rocketmq/issues/4098#issuecomment-1086514284


   LGTM. Could you submit a pr to polish it


-- 
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: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org