Hi fellow WOrriors,

Thought I'd share a tip that works on Mac OS X to simulate a slow internet 
connection. Gives you a nice visceral feel for how your app performs in 
the wild.

You need at least two simple scripts:

throttle_30kb.sh (simulates fast dialup connection):
=======================
sudo ipfw pipe 1 config bw 30KByte/s
sudo ipfw add 1 pipe 1 src-port https
sudo ipfw pipe 2 config bw 30KByte/s
sudo ipfw add 2 pipe 2 dst-port https

throttle_stop.sh (removes speed dampening):
=======================
sudo ipfw flush

In my testing I have a couple of different throttle speed scripts:
15kb -> fast fax speed
30kb -> fast modem speed
100kb -> ISDN speed

You need two computers to test this. You wont see the speed decrease using 
a web browser on the same computer as the webserver. I tried using the 
port that the WO instance was running on instead of "https" in the script. 
That "worked" and didn't need another computer but you run the risk of 
getting the "application not available" message that way. Additionally if 
you connect to your app without a secure socket use "http" instead of 
"https" in the script.

You can learn more about this tool on the Internet by googling:
"ipfw"
"traffic shaping"

I believe "ipfw" stands for "internet protocol fire wall". It is part of 
the FreeBSD tools and is quite powerful. You can specify not only 
bandwidth caps but also "latency". You can also prioritize traffic. 

Here are a few URLs that were useful - there may be better ones for more 
advanced topics:

http://blog.aptivate.org/2010/01/23/make-sure-your-apps-work-in-the-field/

http://www.afp548.com/article.php?story=20060214081244545&mode=print

http://cs.baylor.edu/~donahoo/tools/dummy/tutorial.htm

-- Aaron
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to