Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Workflow Revision API return duplicated records in .config.nodes[] #239

Open
shenqinb-star opened this issue Sep 19, 2022 · 3 comments
Open
Assignees
Labels
bug Something isn't working

Comments

@shenqinb-star
Copy link
Contributor

Describe the bug
Workflow Revision API: Get /workflow/workflow/600f50bb6a7d2472a948cbd0/revision/9 API return duplicated records in .config.nodes[].

To Reproduce

  1. Create a Workflow only have 2 steps (exclude the start and end ones)
  2. Check the flow_workflows_revisions collection. In the collection, 2 items in config.node, and 4 items in dag.tasks(include start and end).

image

3. Invoke Get /workflow/workflow/{workflow Id}/revision/{revision}. check the API reposne. 4 records in ` .config.nodes`, but first one and third one are duplicated, second and forth one are duplicated.

image

Expected Behavior
API only return 2 items in .config.nodes

@shenqinb-star shenqinb-star added the bug Something isn't working label Sep 19, 2022
@shenqinb-star
Copy link
Contributor Author

shenqinb-star commented Sep 19, 2022

@tlawrie @amhudson hi Tyson, ambudson, pls take a look at this issue. I checked the backend code, the reason which cause duplicated items is .config.nodes returned in API is constructed by both .config.nodes of DB collection + .dag.task.properties of DB collection. pls help to clarify it is a bug, or worked as design?

@tlawrie
Copy link
Member

tlawrie commented Sep 19, 2022

Hi @shenqinb-star interesting. I'd have to look into it but maybe @amhudson knows.

Also these endpoints should only be used by the Flow App. For other integrations it should be via the API endpoints. Particularly because we don't version these endpoints, only the API ones, so any changes will just happen.

@tlawrie
Copy link
Member

tlawrie commented Sep 22, 2022

FYI 👀 @gchickma

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants