qiuyanjun888 commented on code in PR #18349:
URL: 
https://github.com/apache/dolphinscheduler/pull/18349#discussion_r3418284535


##########
dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/WorkerGroupServiceImpl.java:
##########
@@ -182,7 +182,9 @@ private void checkWorkerGroupDependencies(WorkerGroup 
workerGroup) {
         // check if the worker group has any dependent environments
         List<EnvironmentWorkerGroupRelation> environmentWorkerGroupRelations =
                 environmentWorkerGroupRelationMapper.selectList(new 
QueryWrapper<EnvironmentWorkerGroupRelation>()
-                        
.lambda().eq(EnvironmentWorkerGroupRelation::getWorkerGroup, 
workerGroup.getName()));
+                        .eq("worker_group_id", workerGroup.getId())
+                        .or(queryWrapper -> 
queryWrapper.isNull("worker_group_id")
+                                .eq("worker_group", workerGroup.getName())));

Review Comment:
   Addressed in 05ef5125df. The worker group dependency check now checks both 
worker_group_id and worker_group name, so worker_group is still treated as 
valid data rather than deprecated fallback only.
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to