Salutm
Vrignaud Etienne wrote:
> Hello,
>
> Recently I have posted a message to report some problems using the Comet
> mechanism.
> http://www.nabble.com/How-terminate-correctly-a-Comet-request-to19886749.html#a19886749.
Apology. I haven't had a chance to help much here. You should ping the
community (ad me_ more often!
> I didn't succeed to find solutions to those problems, so I tried to
> implement all my stuff in a simpler way using directly ARP.
> I am facing also some problems with this ARP implementation. You can
> find in attachment a tar ball of the complete sources.
> My test case works like this:
> 1. First I start the "com.grizzly.test.arp.server.SimpleArpServer"
> application.
> 2. Second I start the "com.grizzly.test.arp.client.ArpClient"
> application.
>
> The goal of my test is to simulate a server side that have to send
> several results for each requests. It means that when my client part
> make a HTTP GET request it have in a streaming way several results as
> they are computed on the server side. In my test case, for each HTTP
> requests the server produce 30 results. And the client part sends 30
> HTTP requests in parallel.
>
> My problem is the following, when the server compute all its 30 results
> very quickly (meaning no sleep between two results) everything just go
> fine. There is no bug. I can run the ArpClient program several times.
>
> But some problems occurs when the server take some time to compute the
> results. (meaning that I put a sleep that can take 0 to 4 seconds
> between two results using the Thread.sleep() method of the ViewAdapter
> class).
> The server part produces no errors on the console, but the client part
> produces many. I put in attachment the console output of the server and
> the client part.
> What I can see is that at the beginning everything seems to be ok, but
> with the time (something like 30 HTTP requests) everything goes wrong on
> the server part. Is there any resource in the server part that needs to
> be released?
> I can't figure out what is exactly the problem.
Let me take a look. Usually you release back the ARP resource by
AsyncExecutor.postExecute(), which recycle all requests/responses objects.
>
> Could you explain me what is the difference between the facts that the
> server response is quick and when it take more time. And what I forgot
> to protect to avoid those kinds of issues.
Let me try to reproduce the test case (thanks a lot BTW).
Thanks!
-- Jeanfrancois
>
> Thanks for you help.
> Regards,
> Etienne VRIGNAUD
>
>
>
> ------------------------------------------------------------------------
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_grizzly.dev.java.net
> For additional commands, e-mail: users-help_at_grizzly.dev.java.net