On May 31, 2011, at 12:44 PM, Markus Jelsma wrote:

> I haven't given it a try but perhaps opening multiple HTTP connections to the 
> update handler will end up in multiple threads thus better CPU utilization. 

My original test case had hundreds of HTTP connections (all to the same URL) 
doing adds, but seemed to use only one CPU core for adding, or to serialize the 
adds somehow, something like that ... at any rate, I couldn't drive CPU use 
above ~120% with that configuration.

This is quite different from queries. For queries (or a rich query-to-add mix), 
I can easily drive CPU use into multiple-hundreds of % CPU, with just a few 
dozen concurrent query connections (running flat out). But adds resist that 
trick. I don't know whether this means that adds really are using a single 
thread, or if they're using multiple threads but synchronizing on some monitor. 
Actually, I can't say I care much: bottom line seems to be I only use one CPU 
core (plus a negligible marginal bit) for adds.

Since I've confirmed that queries spread neatly, I can live with the 
single-thready adds. In production, it seems likely that I'll be more or less 
continuously spending one CPU core on adds, and the rest on queries.

-==-
Jack Repenning
Technologist
Codesion Business Unit
CollabNet, Inc.
8000 Marina Boulevard, Suite 600
Brisbane, California 94005
office: +1 650.228.2562
twitter: http://twitter.com/jrep









Attachment: PGP.sig
Description: This is a digitally signed message part

Reply via email to