FW: [Simpleweb-Support] Simple stops responding
Brought to you by:
niallg
From: Jorge C. <Jor...@ge...> - 2005-07-29 13:16:20
|
Hi Niall! I'm attaching the console output (removed a lot of lines before the end to shrink the file size, I've sent you the zip file to Yahoo) of our server with (at the end) a thread dump... After the thread dump you will find that there is another request (just to see where is it hanging) I've attached the classes with the println I've added, and the Thread.setName (BTW, can you name the threads? it helps a lot when debugging and profiling) It seems that there are no more dequeuers in the SchedulerQueue.java and then the lock.notify() is not executed (I'll check this today). All the threads are in wait(), but they don't seem to be deadlocked. I failed to see our code in the waiting threads, so it seems they are not waiting for some request to be finished (at least it doesn't seems so to me). I hope this helps you in your research and thansk again for your support. Jorge -----Original Message----- From: sim...@li... [mailto:sim...@li...]On Behalf Of Niall Gallagher Sent: Friday, July 29, 2005 5:21 AM To: sim...@li... Subject: Re: [Simpleweb-Support] Simple stops responding Hi Michael, Thank you for this feedback! I am going to be testing this over the next few days to track down this problem, which is obviously pretty severe...I will hopefully have a solution pretty soon! At which time I will upload the updated version! Regards, Niall --- "Michael \"Luni\" Libes" <lun...@ya...> wrote: > Niall, > > I'm successfully tested Simple with web stress > tools. However, > I've found a case that does match what others are > seeing, and > this bug can be triggered with a handful of > requests. > > I have not yet tracked down exactly what is going > on, but the > server "hangs" whenver there are some connections in > the > CLOSE_WAIT state. We were able to trigger this via > a connection > initiated by a J2ME handset when the HTTP connection > was not > properly closed, and similarly with a J2SE > monitoring tool using > java.net.URL. > > For those not aware, CLOSE_WAIT is a TCP state where > the server > has closed the connection but the client has not > acknolwedged > and closed it's side of the connection. (See > http://www.mail-archive.com/com...@ja.../msg043 38.html > and > http://www.tek-tips.com/viewthread.cfm?qid=669906). > > Is there any way within Java to detect when a socket > is in this > state? If so, is there any way to get the socket to > get in a > TIME_WAIT or CLOSED state? > > Luni > > > --- Niall Gallagher <gal...@ya...> > wrote: > > > Hi, > > > > This is interesting, I would like to know what > > conclusions you come to! However, I have tested > simple > > with really enormous loads, for a long period of > time, > > the only problem I could find was with the log > files. > > They were too big and the system ran out of disk > > space! Still requests were being processed fine! > > > > Just downloaded the simple-demo-1.0.tar.gz from > the > > site with no problems. I will send it to you > directly. > > > > Niall > > > > --- Jorge CAMPOS <Jor...@ge...> wrote: > > > > > Hi Niall! > > > > > > First of all thank you for your support. > > > > > > The problem we have is not an HTTP problem. In a > > > network environment is > > > common that connections get broken and I agree > that > > > it is probably logical > > > to close the connection. > > > > > > But our issue is that after stressing Simple > with > > > JMeter, the Simple stops > > > responding. I mean, the ServerSocket continues > to > > > accept connections, but > > > the requests are not treated. The rest of the > > > application continues to run > > > normally. > > > > > > It seems like there are no more resources to > handle > > > the incoming requests > > > (all previous requests were finished, so the > pool > > > should be able to process > > > more, but nothing happens). > > > > > > Henry thought it could be related to the > > > Poller.close(), thinking perhaps a > > > thread was removed from the pool and none was > > > created to replace it. > > > > > > I'm trying to download your demo server to > reproduce > > > the problem, but I > > > can't download it from your download section > > > (timeout, broken file, etc). > > > Can you put the files in the files section of > > > sourceforge (I guess at least > > > one mirror should work for me). > > > > > > Thank you very much for your support. > > > > > > Jorge > > > > > > > > > -----Original Message----- > > > From: > sim...@li... > > > > > > [mailto:sim...@li...]On > > > Behalf Of Niall > > > Gallagher > > > Sent: Tuesday, July 26, 2005 3:24 PM > > > To: sim...@li... > > > Subject: RE: [Simpleweb-Support] Problem when > stress > > > testing an > > > application using SimpleWeb > > > > > > > > > Hi Henry, > > > > > > The reason the connection is closed is because > RFC > > > 2616 says that this is the way this must be > done! > > > For > > > example, that the scenario where the request > > > conatins > > > a larger chunked encoded message body, and then > you > > > read only half of it. If the poller is not > closed, > > > where do you read the next request header from? > Also > > > if you send some wrong information how is the > > > browser > > > supposed to interpret it? > > > > > > Anyway, there is a large section in the HTTP/1.1 > > > specification that discusses pipelining and its > > > semantics. It should provide some more detail. > > > > > > Niall > > > > > > --- Henry Voyer <hen...@ge...> wrote: > > > > > > > Re Hi Neil, > > > > > > > > Well i found the problem and fixed it. And i > would > > > > like your input about it. > > > > The problem is when the client suddently close > the > > > > stream and this happens > > > > often in highly concurrent transactions. > > > > > > > > java.io.IOException: Stream closed > > > > at > > > > > > > > > > java.io.PushbackInputStream.ensureOpen(PushbackInputStream.java:57) > > > > at > > > > > > > > > > java.io.PushbackInputStream.unread(PushbackInputStream.java:181) > > > > at > > > > > > > > > > simple.http.PollerInputStream.available(PollerInputStream.java:114) > > > > at > > > > > > > > > > simple.http.BasicPoller.process(BasicPoller.java:117) > > > > at > > > > > simple.http.Processor.execute(Processor.java:121) > > > > at > simple.http.Processor.run(Processor.java:83) > > > > at java.lang.Thread.run(Thread.java:595) > > > > > > > > Then the exception makes the closes the poller > > > > > > > > This happens, in the class : > simple.http.Processor > > > > > > > > private void execute() throws > > > InterruptedException > > > > { > > > > Object top = queue.dequeue(); > === message truncated === Niall Gallagher __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com ------------------------------------------------------- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf _______________________________________________ Simpleweb-Support mailing list Sim...@li... https://lists.sourceforge.net/lists/listinfo/simpleweb-support |