Javatpoint Logo
Javatpoint Logo

Java forkJoinPool getCommonPoolParallelism() Method

The getCommonPoolParallelism() method of ForkJoinPool class is used to get the parallelism level of the common pool in the integer form.

Syntax

Parameter

No parameter is passed.

Returns

The targeted parallelism level of the common pool

Throws

Does not throw the Exception.

Example 1

Test it Now

Output:

Finder :0    Active threads :1 Left  0 Right 0
 Parallelism level of pool :3

Example 2

Test it Now

Output:

Common Pool Size after  :3
 Parallelism level of pool :3
Is pool use First-in-First-out Scheduling:false
Next TopicJava Forkjoinpool




Please Share

facebook twitter google plus pinterest

Learn Latest Tutorials