incubator-river-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gregg Wonderly <>
Subject Re: TaskManager thread limit
Date Mon, 02 Aug 2010 15:20:54 GMT
Patricia Shanahan wrote:
> Gregg Wonderly wrote:
>> Patricia Shanahan wrote:
> ...
>>> Incidentally, do you know why the default load level is 3, not 1?
>> I am not sure which load level you are referring to.
> ...
> Sorry for the lack of context. I meant the third parameter on the main
> TaskManager constructor:
> loadFactor
> threshold for creating new threads. A new thread is created if the total
> number of runnable tasks (both active and pending) exceeds the number of
> threads times the loadFactor, and the maximum number of threads has not
> been reached.
> The parameterless constructor sets it to 3.0. I can see some special
> cases for a value greater than 1, but would have expected the default to
> be 1. That is, create another thread if the current number of threads is
> less than the maximum and there is at least one task that could be
> running but is waiting for a thread to be available.

Okay, I am not sure of the history of that decision.  I'm with you, that a value 
of 1 would seem the better default, but I am sure that there were system load 
and other issues that happened to affect that when machines were "small" and 
"single processor".


View raw message