Number of threads in parallel mode

Hello, I need to know if (and how) it is possible to get the number “threads” that gradle will create in the parallel mode ?

Thanks a lot, Sébastien

You can get it from the


What are you planning to do with it? This may not do what you want.


thanks for your answer. Basically, In case of sequencial mode I run a command line. However, I can parallelize the use of this command by call it with a specific command line for the computing stage and a last specific call for the merge stage. Therefore, I wrote a small script to unify the use of this command and I want to call it by giving the number of parallel command it needs to run.

You may want to control your own number of parallel workers and just use the StartParameter to know if you should enable parallel mode (parallelThreadCount != 0) instead of using it for the number of workers. Parallel thread count is overloaded for other things right now and we’re trying to detangle them.

ok I’ll do like that. Thanks :slight_smile: