Patent ID: 8296454

Claim:
A method for managing a thread pool in a computing system using threads in the thread pool to execute tasks comprising: (a) calculating a thread variation based on a number of threads; (b) calculating an expected number of threads to be required for a future time based on the calculated thread variation, so as to regulate threads in the thread pool according to the expected number; (c) determining a change from the previous thread variation and the present thread variation; and (d) decreasing an executing frequency of said steps (a) and (b) if the change of the thread variations at said step (c) is determined as small and otherwise increasing the executing frequency of said steps (a) and (b), wherein said step (c) includes: (c1) setting a sampling constant defining a number of the thread variations to be sampled per hour; (c2) sampling the thread variations as many times per hour as the sampling constant; (c3) calculating an average and a variance of the sampled thread variations; (c4) applying the sampled value, the average and the variance of the sampled thread variations to a Gaussian probability density function; and (c5) determining the change of the thread variations as small if the change of the thread variations is out of a predetermined reference range from a center of a result of the application of the Gaussian probability density function and as not small otherwise, wherein the Gaussian probability density function is represented by f ⁡ ( x ) = ⅇ - ( x - m ) 2 / 2 ⁢ σ 2 2 ⁢ πσ 2 where, x represents the thread variation, m represents the average of the thread variations, and σ2 represents the variance of the thread variations, and wherein said step (d) includes: (d1) increasing the executing frequency of said steps (a) and (b) by a predetermined reference amount in case that it is determined that the change of the thread variations is out of the reference range from the center of the result of the application of the Gaussian probability density function in said step (c5); and (d2) decreasing the executing frequency of said steps (a) and (b) by the predetermined reference amount in case that it is determined that the change of the thread variations is within the reference range from the center of the result of the application of the Gaussian probability density function in said step (c5).