WPG - Active connections + persistent idle connections

Sanjeevi Rangan sanjeevirangan at gmail.com
Fri Mar 18 12:33:30 UTC 2016

Hi Alex,

Thanks for the detailed explanation. I have tried with the following values
to check if robots are not closing connections.

        req_methods = ["HEAD"];
        req_rate = 2/1min;
        MimeHeader header1 = 'Connection: keep-alive';
        MimeHeader header2 = 'Proxy-Connection: keep-alive';
        http_headers = [header1: 100%, header2:100%];
        pconn_use_lmt = const(2147483647); // Persistent connections - max
        idle_pconn_tout = 60min;

Though there are two requests per min, the connections are closed. This
could be because of proxy as you mentioned. While I have to confirm on what
proxy does, I have a question on sending that first 'Head' request. The
req_rate parameter controls how many requests can be sent for given
duration. But the first request seems to be sent only after that specified
duration. That is, if the req_rate = 1/10 min; then the first request is
not sent until the 10th min approximately. Is there a way to send that
first 'Head' request and not send any further requests at all to keep the
connections alive? Thanks again for prompt response!


On Fri, Mar 18, 2016 at 7:58 AM, Alex Rousskov <
rousskov at measurement-factory.com> wrote:

> On 03/17/2016 12:45 PM, Sanjeevi Rangan wrote:
> > I am trying to simulate persistent idle connections (that won't
> > contribute to the actual traffic) along with the workload that
> > contributes to the traffic. For an instance, if the actual test has 100
> > concurrent connections that has content size of 64KB, I would like to
> > have few sockets (say 50) in established state without sending any
> > requests. The requests would go via proxy. Is it possible to keep the
> > socket connections (client->proxy->server) alive with out sending any
> > requests (or just keep alives that doesn't send much of data) in WPG?
> Yes, provided the proxy plays along. Polygraph can only control its side
> of the robot-proxy and proxy-server connections. The proxy may decide to
> close its connection at any time regardless of what Polygraph does.
> To accomplish the above, use 50 Robots with large constant pconn_use_lmt
> that avoid non-idempotent requests. Such a robot will not close its side
> of the idle persistent connection until its idle timeout expires (which
> you control via idle_pconn_tout).
> Same for Polygraph Server, except you only need one to serve all 50 robots.
> I believe all of the PGL options mentioned above are documented at
> http://www.web-polygraph.org/docs/reference/pgl/types.html#type:docs/reference/pgl/types/Agent
> Currently, there is no way to tell Polygraph to open a new connection
> (and send a new request) as soon as the proxy closes a previously idle
> persistent connection. That would be a generally useful option to add.
> It would make your test setup less dependent on the proxy behavior
> because Polygraph will maintain a pool of mostly idle 50 HTTP
> connections even if the proxy closes idle connections after a few
> seconds of inactivity.
> Currently, there is no way to configure Robots to open a connection
> without sending at least one request on that connection. We could add an
> option to delay request sending (after opening a connection for that
> request), but that feels like going a little too far in TCP testing
> direction. Besides, proxies may be more impatient with virgin
> connections waiting for their first request than with previously used
> idle persistent connections so you may want to send that first GET or
> HEAD anyway.
> > I can even run two instances of WPG server (listening to two different
> > ports) and clients (one for the active connections and another one for
> > idle connections).
> One polygraph-client (or polygraph-server) instance can support
> thousands of robots (or server agents). You may want to create agents
> dedicated to this "idle connection pool" task, but there is no need to
> use many Polygraph instances to accomplish that. Just describe
> everything your test needs in one PGL workload.
> HTH,
> Alex.

*Sanjeevi Rangan*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.web-polygraph.org/pipermail/users/attachments/20160318/66857566/attachment.html>

More information about the Users mailing list