title: How to mass http request gevent?
body: <p>I found this example from gevent documentation but i want to control the concurrent requests done by gevents:</p>
  
  <pre><code>import gevent
  import urllib2
  
  from gevent import monkey
  monkey.patch_all()
  
      urls = ['http://www.google.com', 'http://www.example.com', 'http://www.python.org']
  
  def print_head(url):
      print 'Starting %s' % url
      data = urllib2.urlopen(url).read()
  
      print '%s: %s bytes: %r' % (url, len(data), data[:50])
  
  jobs = [gevent.spawn(print_head, url) for url in urls]
  gevent.joinall(jobs, timeout=2)
  </code></pre>
  
  <p>How can I limit my connections to 50 if for example I have 5000 urls to request?</p>