Metadata-Version: 2.1
Name: gevent_requests
Version: 0.6.1
Summary: Use requests with gevent in your production
Home-page: https://github.com/belingud/grequests
Author: Belingud
Author-email: im.victor@qq.com
License: BSD
Platform: any
Classifier: Environment :: Web Environment
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: BSD License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
Classifier: Topic :: Software Development :: Libraries :: Python Modules
License-File: LICENSE
License-File: AUTHORS.rst


Gevent-Requests allows you to use Requests with Gevent to make asynchronous HTTP
Requests easily.
And this project also allow your own custom useage with gevent in your production environment,
for example your can use it with flask like:

>>> from gevent import monkey
>>> monkey.patch_all(thread=False, select=False)

Usage
-----

Usage is simple::

    >>> # First patch the socket
    >>> import gevent_requests

    >>> urls = [
    >>>     'http://www.heroku.com',
    >>>     'http://tablib.org',
    >>>     'http://httpbin.org',
    >>>     'http://python-requests.org',
    >>>     'http://kennethreitz.com'
    >>> ]

Create a set of unsent Requests::

    >>> rs = (gevent_requests.get(u) for u in urls)

Send them all at the same time::

    >>> gevent_requests.gmap(rs)
    [<Response [200]>, <Response [200]>, <Response [200]>, <Response [200]>, <Response [200]>]



