Splitting / Parallelism support via filter flags
See original GitHub issueMany CI services offer split job execution on multiple runners in parallel. For instance, CircleCI calls this feature “parallelism”.
You could configure your build job with parallelism: 3
, which would spawn 3 runners in total, each with these environment variables:
CIRCLE_NODE_TOTAL=3
,CIRCLE_NODE_INDEX=0
CIRCLE_NODE_TOTAL=3
,CIRCLE_NODE_INDEX=1
CIRCLE_NODE_TOTAL=3
,CIRCLE_NODE_INDEX=2
It would be awesome, if lerna
could natively support deterministic splitting on the filter flags level, to make commands like lerna run
“just work”.
For instance, with command flags inspired from ember-exam
:
$ yarn lerna run \
--stream \
--concurrency 1 \
--split $CIRCLE_NODE_TOTAL
--partition $CIRCLE_NODE_INDEX
test
Would you be open to a pull request implementing that feature?
Edit: I published lerna-parallelism
, which does exactly that.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:11
Top Results From Across the Web
Speed Up CI Test Pipelines Using Parallelism - Harness.io Docs
The first time you run with parallelism, the pipeline splits the tests by file size and collects timing data for all tests.
Read more >Tuning TBB Algorithms: Granularity, Locality, Parallelism, and ...
In Chapter 2, we described the generic parallel algorithms provided by the TBB library and gave a few examples to show how they...
Read more >GNU Parallel Tutorial
GNU Parallel Tutorial . This tutorial shows off much of GNU parallel's functionality. The tutorial is meant to learn the options in...
Read more >When to Use a Parallel Stream in Java - Baeldung
The fork-join framework is in charge of splitting the source data between worker threads and handling callback on task completion. Let's take a ......
Read more >Parallel Algorithms - CMU School of Computer Science
the parallelism in an algorithm can be exploited by using multiple functional units, ... In this chapter we divide parallel models into two...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
🤦 omg, I didn’t notice. Sorry, it’s published now. 😅
Related StackOverflow question someone asked on May 12th: https://stackoverflow.com/questions/61759348/is-there-a-way-to-split-my-tests-and-have-them-run-parallel-in-my-lerna-monorepo