You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@inlong.apache.org by do...@apache.org on 2023/10/07 07:52:20 UTC
[inlong] branch master updated: [INLONG-9007][SDK] ClientList out of bounds (#9014)
This is an automated email from the ASF dual-hosted git repository.
dockerzhang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/inlong.git
The following commit(s) were added to refs/heads/master by this push:
new dc5eb894e3 [INLONG-9007][SDK] ClientList out of bounds (#9014)
dc5eb894e3 is described below
commit dc5eb894e31a77e624a910460661c5876fd9d8c3
Author: SCUTking <10...@users.noreply.github.com>
AuthorDate: Sat Oct 7 15:52:15 2023 +0800
[INLONG-9007][SDK] ClientList out of bounds (#9014)
---
.../main/java/org/apache/inlong/sdk/dataproxy/network/ClientMgr.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/inlong-sdk/dataproxy-sdk/src/main/java/org/apache/inlong/sdk/dataproxy/network/ClientMgr.java b/inlong-sdk/dataproxy-sdk/src/main/java/org/apache/inlong/sdk/dataproxy/network/ClientMgr.java
index 998694de5e..8e1f878591 100644
--- a/inlong-sdk/dataproxy-sdk/src/main/java/org/apache/inlong/sdk/dataproxy/network/ClientMgr.java
+++ b/inlong-sdk/dataproxy-sdk/src/main/java/org/apache/inlong/sdk/dataproxy/network/ClientMgr.java
@@ -467,7 +467,7 @@ public class ClientMgr {
int randomId = random.nextInt();
client = clientList.get(randomId % currSize);
if (client != null && client.isActive()) {
- clientId = randomId;
+ clientId = randomId % currSize;
break;
}
maxRetry--;