-
-
Notifications
You must be signed in to change notification settings - Fork 371
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
drop step.group in favour of depends_on to create a DAG #1860
Comments
what about |
Yes, same naming as for pipelines would be the best way to go imho |
one big downside! and what esp. makes it breaking!!!: now we assume that steps need to be run in sequence if not told otherwise (because it is what you normally want) so what I think is really important: by default it should run sequential (that's just good UX-Design) so what about a workflow config: |
so I propose:
that way it also would be non breaking |
we should explicite write that down as one of our core values:
|
In drone, it is also sequential until you add the first |
That sounds nice as long as you dont have a workflow with steps that all can run paralel |
Right, how about |
I would call that not easy to lint, parse and sanitize ... Also it would increase yaml config more ... The more i think and talk about this with others the more i think we should have a workflow flag "parallel: true" and depends_on ... for the DAG |
One more idea: to execute steps in parallel or not can be decided on whether the steps in the yaml are defined as a list or a dictionary.
This is of course not backwards compatible und would require some versioning of the pipeline syntax. A modified example from the docs... parallel execution with DAG:
sequential execution:
|
This sounds like the best option to me atm. |
That’s also more or less, how it works in GitLab CI: By default, everything is sequential, and jobs in the same See https://docs.gitlab.com/ee/ci/yaml/index.html#needs. So I think this would be a pretty good pattern, since both users of GitLab CI and Drone are already familiar with it. |
I personally think see: https://go.dev/play/p/JziUknAwKvY and yes I know there is a golang trick to achive it ... -> https://go.dev/play/p/M1XlwhSUZn_X but yaml do exist outside of golang to and each parser do behave bit different if it belongs to this edgecases |
To be honest, I think it’s weird that parsers would not implement this in a way so that combining deserialisation and serialisation results in the identity. There is obviously a difference between a property being empty, and it not existing at all in yaml, so parsers should respect that, imo. Doing it the other way round, as you suggest, and making the "empty array" case and the "not set" case behave equally, is extremely surprising from a user perspective: Users could still write By the way, GitHub actions circumvents this problem by executing jobs in parallel, by default, instead of sequentially:
(https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobs) So the empty array case and and the property missing case do have the same meaning semantically. But not sure if it would be worth a breaking change to change that default in woodpecker… |
Support parallelism inside a pipeline via a DAG. This requires a way to define step dependencies which can then allow the runner to build said DAG. Edit: I see
group
provides something similar for static fan-out, but certainly not as flexible as defining dependencies directly.Originally posted by @silverwind in #567 (comment)
The text was updated successfully, but these errors were encountered: