From b41e86aaa4d5c4452c1fbb3baa255237726e1ee6 Mon Sep 17 00:00:00 2001 From: CaptainB Date: Wed, 28 Aug 2024 14:05:36 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=80=A7=E8=83=BD=E6=B5=8B=E8=AF=95):=20?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=80=A7=E8=83=BD=E6=B5=8B=E8=AF=95=E9=83=A8?= =?UTF-8?q?=E7=BD=B2=E5=A4=9A=E4=B8=AA=E8=8A=82=E7=82=B9=E6=97=B6=E5=87=BA?= =?UTF-8?q?=E7=8E=B0time=20sync=20=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/io/metersphere/controller/JmeterFileController.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/performance-test/backend/src/main/java/io/metersphere/controller/JmeterFileController.java b/performance-test/backend/src/main/java/io/metersphere/controller/JmeterFileController.java index c0e3654a6f..6cbf2259a5 100644 --- a/performance-test/backend/src/main/java/io/metersphere/controller/JmeterFileController.java +++ b/performance-test/backend/src/main/java/io/metersphere/controller/JmeterFileController.java @@ -36,7 +36,7 @@ public class JmeterFileController { try { // 保存当前节点状态到redis String reportIdKey = "jmeter_ready:" + reportId; - stringRedisTemplate.opsForHash().put(reportIdKey, resourceIndex, 1); + stringRedisTemplate.opsForHash().put(reportIdKey, reportId + "_" + resourceIndex, "1"); // 设置30分钟过期 stringRedisTemplate.expire(reportIdKey, 30 * 60, TimeUnit.SECONDS); // 返回当前已经准备好的节点数量