WebPagetest Forums

Full Version: nodejs-Agent and traffic-shaping
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hey guys,

I'm working at Iteratec GmbH and enabling the multistep-feature for your nodejs-Agent which works quite good!
Now I'm trying to get the traffic-shaping feature working but the documentation doesn't match the code.

At the docu it says, there should be a switch "--trafficShaper" and "--trafficShaperArg". By that switches you should be allowed to give the client a customized traffic-shaping script.
But in the code (wptdriver.bat and .sh) I can't find those switches. Aren't they implemented yet or did I miss them?

Second thing: if you use the builtin ipfw traffic-shaping, are there network performance problems, if 3 nodejs-agents are using traffic-shaping over the same notebook-connection?

Best regards,
Birger
1. I believe the traffic shaper is executed through the daemon that's running (the agent), so when it grabs a job from the WPT server, it sees the traffic shaping bit and executes it.
https://github.com/WPO-Foundation/webpag...in.js#L616

2. Depends on how much load you're putting on the connection at any time.
Thanks for your fast answer!

You're right, that's the built-in traffic-shaping which uses by default ipfw of the "host"-notebook.

But the documentation talks about the possibility to use a selfmade traffic-shaping script by using the "--trafficShaper" switch. By setting this switch the application (especially your linked function) should use this selfmade script instead of ipfw.
But I can't find that switch in the existing start-scripts.
(02-03-2015 03:37 AM)BirgerK Wrote: [ -> ]But the documentation talks about the possibility to use a selfmade traffic-shaping script by using the "--trafficShaper" switch. But I can't find that switch in the existing start-scripts.

Ah, yes .. it's a custom implementation and hasn't been integrated to the "core"
See https://github.com/WPO-Foundation/webpag...issues/147

You might be able to find some modification in the text/links there to the scripts that will help you.
Reference URL's