← back to the blog
fousa blog
24
JAN
Ruby script to check your website's response time
This is a small ruby script that you can use to check your server response time.
It could come in handy when you want to use it to check your response time and analyze it.
You can run the script you have to pass 2 arguments. The first on is the interval time (in seconds), and the second one is the website to check.
> ./response 10 http://www.fousa.be/This will execute a request to http://www.fousa.be/ every 10 seconds.
Here is the code on Gist:
UPDATE
I already received 2 updates on my code thanks to Simon and Nicolas.
You can check out both versions here and here.
This seems to be the best solution... Nicolas (the awesome) won...
Send me some feedback!
I tried to make it a little shorter and more "Rubyesque": http://gist.github.com/299037
written by Nicolas jacobeus → 7 months ago