Re: Unexpected low CPU usage
Johan Stuyts <[email protected]> Fri, 18 Jan 2008 20:00:10 +0100
| Newsgroups | gmane.comp.windows.devel.java.advanced |
|---|---|
| Message-ID | <op.t4422kbrc4vsc3@audioslave> |
> Are you simply loading it enough? I can keep the CPU utilized when I run a single-threade client using the RMI and XML-RPC. I get approx. 1500 and 400 roundtrips respectively. > Your stuff might just be better than the RMI thing! Smile and be happy! I get a lower score for the SOAP protocol: approx. 300, and although I expect it to be much lower than RMI I don't want to jump to the wrong conclusions. The amount of data going back and forth is small (approx. 250 KB per second when running the RMI client), so the whole thing should be CPU-bound: marshalling, unmarshalling, authorization, etc. I attached a graph showing the CPU utilization. I hope it gets through. If not, you can download it here: http://download.cl1p.net/johanstuyts/ The first bump is from RMI, the second and third are from XML-RPC and the last two are from SOAP. They all do 11,000 roundtrips. The tests were run on a dual core processor. You can clearly see at least one core is busy all the time while the RMI and XML-RPC clients are running. In my opinion the correct behavior should be that the same SOAP CPU usage is spread over less time so one core is constantly busy too. > When client and server are on distinct boxes, you must make sure there > aren't any hiccups on the line - see to that it is full duplex 1 Gbps > links, so that both throughput is super, and latency is nil. I understand that I need multiple clients and/or a very good network if I want the CPU to be used fully on the server when the clients and the server are on different hosts. But I can't get it to go to 100 % when running on the same host. > See how much you manage to pull through the thing (scale up the load). > > You should measure lag - are the responses coming steadily very fast? > When the response times starts to climb (exponentially), you've hit some > roof - if the CPU at that time still isn't 100%, you've got some other > bottleneck - maybe some very bad synching or something..? I thought about locking and synchronization but the whole thing is basically single-threaded as a single thread is running in one client. Johan Stuyts =================================== This list is hosted by DevelopMentor® http://www.develop.com View archives and manage your subscription(s) at http://discuss.develop.com