From 663d652f3607c3f448f60ffe2eecf806a348273d Mon Sep 17 00:00:00 2001 From: dcy Date: Tue, 11 Jun 2024 15:21:25 +0800 Subject: [PATCH] inner-2396:fix delayThreshold not work properly --- .../actiontech/dble/backend/datasource/PhysicalDbInstance.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/com/actiontech/dble/backend/datasource/PhysicalDbInstance.java b/src/main/java/com/actiontech/dble/backend/datasource/PhysicalDbInstance.java index 4b967ddaed..01cfa7a938 100644 --- a/src/main/java/com/actiontech/dble/backend/datasource/PhysicalDbInstance.java +++ b/src/main/java/com/actiontech/dble/backend/datasource/PhysicalDbInstance.java @@ -391,7 +391,7 @@ boolean canSelectAsReadNode() { return false; } boolean isSync = dbSynStatus == MySQLHeartbeat.DB_SYN_NORMAL; - boolean isNotDelay = slaveBehindMaster <= this.dbGroupConfig.getDelayThreshold(); + boolean isNotDelay = slaveBehindMaster <= (this.dbGroupConfig.getDelayThreshold() / 1000); return isSync && isNotDelay; }