Merge remote-tracking branch 'origin/3.0' into enh/opt-transport

This commit is contained in:
yihaoDeng 2024-09-29 11:15:39 +08:00
parent e7510e8cb3
commit 8276cd5cbe
1 changed files with 4 additions and 1 deletions

View File

@ -3437,7 +3437,10 @@ static int32_t delConnFromHeapCache(SHashObj* pConnHeapCache, SCliConn* pConn) {
int32_t compareHeapNode(const HeapNode* a, const HeapNode* b) {
SCliConn* args1 = container_of(a, SCliConn, node);
SCliConn* args2 = container_of(b, SCliConn, node);
if (transQueueSize(&args1->reqsToSend) > transQueueSize(&args2->reqsToSend)) {
int32_t totalReq1 = transQueueSize(&args1->reqsToSend) + transQueueSize(&args1->reqsSentOut);
int32_t totalReq2 = transQueueSize(&args2->reqsToSend) + transQueueSize(&args2->reqsSentOut);
if ( totalReq1 > totalReq2) {
return 0;
}
return 1;