njnu-seafish commented on PR #17576:
URL:
https://github.com/apache/dolphinscheduler/pull/17576#issuecomment-3400506605
**In the code, there are numerous Map data structures that use task names as
key values.**
> java.util.concurrent.CompletionException: java.lang.IllegalStateException:
Duplicate key TaskDefinition(id=124, code=154336501540032, name=shell_01,
version=1, description=, projectCode=148941944330592, userId=2, taskType=SHELL,
taskParams={"localParams":[],"rawScript":"echo \"111\"","resourceList":[]},
taskParamList=[], taskParamMap=null, flag=YES, taskPriority=MEDIUM,
userName=null, projectName=null, workerGroup=default,
environmentCode=144873539254368, failRetryTimes=0, failRetryInterval=1,
timeoutFlag=CLOSE, timeoutNotifyStrategy=null, timeout=0, delayTime=0,
resourceIds=null, createTime=Sat Oct 11 10:33:35 GMT+08:00 2025, updateTime=Sat
Oct 11 10:33:35 GMT+08:00 2025, modifyBy=null, taskGroupId=0,
taskGroupPriority=0, cpuQuota=-1, memoryMax=-1, taskExecuteType=BATCH)
at
java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:273)
at
java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:280)
at
java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1606)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:750)
Caused by: java.lang.IllegalStateException: Duplicate key
TaskDefinition(id=124, code=154336501540032, name=shell_01, version=1,
description=, projectCode=148941944330592, userId=2, taskType=SHELL,
taskParams={"localParams":[],"rawScript":"echo \"111\"","resourceList":[]},
taskParamList=[], taskParamMap=null, flag=YES, taskPriority=MEDIUM,
userName=null, projectName=null, workerGroup=default,
environmentCode=144873539254368, failRetryTimes=0, failRetryInterval=1,
timeoutFlag=CLOSE, timeoutNotifyStrategy=null, timeout=0, delayTime=0,
resourceIds=null, createTime=Sat Oct 11 10:33:35 GMT+08:00 2025, updateTime=Sat
Oct 11 10:33:35 GMT+08:00 2025, modifyBy=null, taskGroupId=0,
taskGroupPriority=0, cpuQuota=-1, memoryMax=-1, taskExecuteType=BATCH)
at
java.util.stream.Collectors.lambda$throwingMerger$0(Collectors.java:133)
at java.util.HashMap.merge(HashMap.java:1255)
at java.util.stream.Collectors.lambda$toMap$58(Collectors.java:1320)
at java.util.stream.ReduceOps$3ReducingSink.accept(ReduceOps.java:169)
at
java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1384)
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
at
java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:472)
at
java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708)
at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at
java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:566)
at
org.apache.dolphinscheduler.server.master.engine.graph.WorkflowGraph.<init>(WorkflowGraph.java:51)
at
org.apache.dolphinscheduler.server.master.engine.graph.WorkflowGraphFactory.createWorkflowGraph(WorkflowGraphFactory.java:54)
at
org.apache.dolphinscheduler.server.master.engine.command.handler.AbstractCommandHandler.assembleWorkflowGraph(AbstractCommandHandler.java:122)
at
org.apache.dolphinscheduler.server.master.engine.command.handler.AbstractCommandHandler.handleCommand(AbstractCommandHandler.java:79)
at
org.apache.dolphinscheduler.server.master.engine.workflow.runnable.WorkflowExecutionRunnableFactory.doCreateWorkflowExecutionRunnable(WorkflowExecutionRunnableFactory.java:71)
at
org.apache.dolphinscheduler.server.master.engine.workflow.runnable.WorkflowExecutionRunnableFactory.createWorkflowExecuteRunnable(WorkflowExecutionRunnableFactory.java:56)
at
org.apache.dolphinscheduler.server.master.engine.workflow.runnable.WorkflowExecutionRunnableFactory$$FastClassBySpringCGLIB$$597b7266.invoke(<generated>)
at
org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218)
at
org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:792)
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
at
org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:762)
at
org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:123)
at
org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:388)
at
org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119)
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
at
org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:762)
at
org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:707)
at
org.apache.dolphinscheduler.server.master.engine.workflow.runnable.WorkflowExecutionRunnableFactory$$EnhancerBySpringCGLIB$$c423f38c.createWorkflowExecuteRunnable(<generated>)
at
org.apache.dolphinscheduler.server.master.engine.command.CommandEngine.lambda$bootstrapCommand$2(CommandEngine.java:153)
at
java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1604)
... 3 common frames omitted
--
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]