2 ms·
i re-wrote it to just loop over the urls and fetch, results below. >> time ruby parallel.rb http://google.com http://google.com: 301 Moved Permanently http://g
by bigdubs 12y ago
i re-wrote it to just loop over the urls and fetch, results below.
>> time ruby parallel.rb
http://google.com http://google.com: 301 Moved Permanently
http://grantland.com http://grantland.com: 200 OK
http://espn.go.com http://espn.go.com: 200 OK
http://www.cnn.com http://www.cnn.com: 200 OK
real 0m0.595s
user 0m0.099s
sys 0m0.045s
~/code/ruby >> time ruby serial.rb
http://www.cnn.com http://www.cnn.com: 200 OK
http://espn.go.com http://espn.go.com: 200 OK
http://grantland.com http://grantland.com: 200 OK
http://google.com http://google.com: 301 Moved Permanently
real 0m1.495s
user 0m0.116s
sys 0m0.053s