diff --git a/backend/services/system-setting/src/main/java/io/metersphere/system/service/TestResourcePoolService.java b/backend/services/system-setting/src/main/java/io/metersphere/system/service/TestResourcePoolService.java index 327e312583..0ea1d3e0e2 100644 --- a/backend/services/system-setting/src/main/java/io/metersphere/system/service/TestResourcePoolService.java +++ b/backend/services/system-setting/src/main/java/io/metersphere/system/service/TestResourcePoolService.java @@ -111,9 +111,11 @@ public class TestResourcePoolService { if (CollectionUtils.isEmpty(testResourceDTO.getNodesList())) { testResourceDTO.setNodesList(new ArrayList<>()); } - TestResourcePoolValidateService testResourcePoolValidateService = CommonBeanFactory.getBean(TestResourcePoolValidateService.class); - if (testResourcePoolValidateService != null) { - testResourcePoolValidateService.validateNodeList(testResourceDTO.getNodesList()); + if (StringUtils.equalsIgnoreCase(testResourcePool.getType(), ResourcePoolTypeEnum.NODE.name())){ + TestResourcePoolValidateService testResourcePoolValidateService = CommonBeanFactory.getBean(TestResourcePoolValidateService.class); + if (testResourcePoolValidateService != null) { + testResourcePoolValidateService.validateNodeList(testResourceDTO.getNodesList()); + } } String configuration = JSON.toJSONString(testResourceDTO); TestResourcePoolBlob testResourcePoolBlob = new TestResourcePoolBlob();