Hello Christiaan,

> Is it correct to assume that for every (HTTP) connection, mentioned
> above, only 1 request can be made at a time and that the requests can
> be part of the same connection if keep-alive is used (But of course
> multiple HTTP connections can still be made in parallel) If this is
> true then it most probably is for SSL.

Yes, this is true for both.

> Now using a new thread for every request is quite expensive for the
> server, lets say this is mainly due to the new SSL connection that is
> created for every thread, and I would like to make multiple requests
> per SSL connection as well. This is fine as, as long as keep-alive is
> enabled I can make more than one request per SSL connection BUT these
> requests are sequential and so I can't maintain my requested request
> rate if the server does not respond within 1/x seconds.

That is correct. But no matter what you do, a connection can only
be used for coupled request/response pairs. Even with pipelining,
you can't get the response for request 2 until after the response
for request 1. And without pipelining (an optional feature of
servers, btw), you have to receive a response completely before
you can send the next request. Keep-alive will reduce the overhead
of establishing connections, but no more. If a response is not read
within 1/x seconds and the connection returned to the manager, you
have to open a new connection or wait until one becomes available.

If you want to guarantee a fixed rate of requests to the server,
you have to live with an excessive number of connections. If you
decide to use HttpCore-NIO, you can at least reduce the number of
threads. Though that will also reduce the maximum throughput of
your test application, since fewer threads have to serve the same
number of connections.
You can put a bound on the number of connections by defining a
response time limit and aborting connections if the response
isn't received in time. With x requests per seconds and a limit
of n seconds, you'll need at most n*x simultaneous connections.

hope this helps,
  Roland


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to