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

Render pipeline dependency graphs asynchronously #43

Open
karkhaz opened this issue Sep 20, 2021 · 0 comments
Open

Render pipeline dependency graphs asynchronously #43

karkhaz opened this issue Sep 20, 2021 · 0 comments

Comments

@karkhaz
Copy link
Contributor

karkhaz commented Sep 20, 2021

Currently, Litani forks out to dot in the main thread. This blocks report generation (and other aspects of the Litani run) from happening until all pipeline dependency graphs are completed (i.e. one invocation of dot for every pipeline).

What should happen instead is that the PipelineDepgraphRenderer render method should be a coroutine, which uses asyncio or threading to spawn dot. This will happen in its own process, freeing the main litani run-build thread. The coroutine should update the "dependencies_url" SVG only when the SVG gets written. The Jinja template should check, for each pipeline, whether the "dependencies_url" key exists and is set; if not, it will simply not add the dependency graph to the pipeline page.

@karkhaz karkhaz added this to the Graph output revamp milestone Sep 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant