Skip to content

Instantly share code, notes, and snippets.

@nepsilon
Last active February 19, 2017 12:45
Show Gist options
  • Save nepsilon/10fdbf3b657b1523bcd9 to your computer and use it in GitHub Desktop.
Save nepsilon/10fdbf3b657b1523bcd9 to your computer and use it in GitHub Desktop.
How to test your webapp for heavy traffic? — First published in fullweb.io issue #24

How to test your web app for heavy traffic?

Load testing is a good way to understand your website or web app behaviour under high traffic. Here is how to use siege, a simple CLI tool.

Note: Use siege only on sites you own as its traffic could be interpreted as a DDOS attack.

Using 100 concurrent requests and up to 3 seconds between requests:

$ siege -d3 -c100 mysite.com 

Use -i to specify a URL list, siege will randomly hit them:

$ siege -d3 -c100 -i urls.txt 

Stop it with Ctrl+C, it will give you an output like this:

Transactions:            3351 hits
Availability:            100.00 %
Elapsed time:            41.69 secs
Data transferred:        2.12 MB
Response time:           0.71 secs
Transaction rate:        80.38 trans/sec
Throughput:              0.05 MB/sec
Concurrency:             56.96
Successful transactions: 3351
Failed transactions:     0
Longest transaction:     1.89
Shortest transaction:    0.00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment