Jan Wieck <[EMAIL PROTECTED]> writes: > This proves that limiting the number of concurrently running > transactions is sufficient to keep the system load down. > Combined these two look as follows: > - We start with a fairly high setting in the semaphore. > - When the system load exceeds the high-watermark, we don't > increment the semaphore back after transaction end (need > to ensure that at least a small minimum of xacts is left, > but that's easy). > - When the system goes back to normal load level, we slowly > increase the semaphore again. This is a nice way of dealing with the slow reaction time of the load average --- you don't let it directly drive the decision about when to start a new transaction, but instead let it tweak the ceiling on number of concurrent xacts. I like it. You probably don't need to have any additional "slowness" in the loop other than the inherent averaging in the kernel's load average. I'm still concerned about portability issues, and about whether load average is really the right number to be looking at, however. regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]
- Re: [HACKERS] refusing connections based on load ... Nathan Myers
- Re: [HACKERS] refusing connections based on load ... Neal Norwitz
- Re: [HACKERS] refusing connections based on load ..... Tom Lane
- Re: [HACKERS] refusing connections based on loa... Doug McNaught
- Re: [HACKERS] refusing connections based on... Peter Eisentraut
- Re: [HACKERS] refusing connections based on... Christopher Masto
- Re: [HACKERS] refusing connections based on... Tom Lane
- Re: [HACKERS] refusing connections based on... Peter Eisentraut
- Re: [HACKERS] refusing connections based on... The Hermit Hacker
- Re: [HACKERS] refusing connections based on... Jan Wieck
- Re: [HACKERS] refusing connections based on... Tom Lane
- Re: [HACKERS] refusing connections based on... The Hermit Hacker
- Re: [HACKERS] refusing connections based on... Tom Lane
- Re: [HACKERS] refusing connections based on... The Hermit Hacker
- Re: [HACKERS] refusing connections based on... Tom Lane
- Re: [HACKERS] refusing connections based on... Vince Vielhaber
- Re: [HACKERS] refusing connections based on... The Hermit Hacker
- Re: [HACKERS] refusing connections based on... Vince Vielhaber
- Re: [HACKERS] refusing connections based on... The Hermit Hacker
- Re: [HACKERS] refusing connections based on... Vince Vielhaber
- Re: [HACKERS] refusing connections based on... Tom Lane