Skip to content

[Bug] When contains multiple sub-processes, the task instance in the sub-process instance obtains duplicate parameters of the pre-task instance. #16879

@AlanZQ

Description

@AlanZQ

Search before asking

  • I had searched in the issues and found no similar issues.

What happened

在工作流中,创建多个子流程,例如创建12个子流程,子流程在获取上游任务参数时,会出现覆盖/错误/以及12个节点拿到的参数完全一致,这不符合预期
通过数据库中查询来看,生成的12的子流程实例,参数没有问题,但是在varpool的设置阶段,获取parent_process_instance_id所对应的varpool,是相同的,这导致子流程实例中的任务实例,执行时的参数永远是相同的

iShot_2024-12-05_10 44 15

What you expected to happen

通过数据库中查询来看,生成的12的子流程实例,参数没有问题,但是在varpool的设置阶段,获取parent_process_instance_id所对应的varpool,是相同的,这导致子流程实例中的任务实例,执行时的参数永远是相同的
通过debug setSubProcessParam这个方法,能够看出每个子流程任务实例获取到的varpool参数都有问题,并且会随机出现重复

How to reproduce

我已经验证了3.2.1的standalone镜像,3.2.2的standalone镜像,debug镜像代码,都存在此问题,也可以在这两个镜像web服务页面,复现。我提供了我的验证工作流json,⚠️注意:导入后需要更改主流程中子流程的引用为新的id
workflow_1733366901095.json

Anything else

No response

Version

3.2.x

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinghelp wantedExtra attention is needed

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions