Website built from v0.20.0-3-g918753e

This commit is contained in:
Sergey Shepelev 2016-12-12 01:27:50 +03:00
parent cd7d61d46e
commit 588ef1f619
40 changed files with 2830 additions and 358 deletions

View File

@ -1,3 +1,24 @@
0.20.0
======
* IMPORTANT: removed select.poll() function
* DNS resolving is always green with dnspython bundled in
* greenio: only trampoline when we block
* convenience: listen() sets SO_REUSEPORT when available; Thanks to Zhengwei Gao
* ssl: Fix "TypeError: read() argument 2 must be read-write bytes-like object, not None"
* greenio: _recv_loop behaviour with recv_into on closed sock
* ipv6: getaddrinfo would fail with scope index
* green.zmq: Support {send,recv}_{string,json,pyobj} wrappers
* greendns: Return answers from /etc/hosts despite nameserver errors
* patcher: fixed green existing locks fail (Python3)
* Add DAGPool, a dependency-driven greenthread pool
* wsgi: Unix socket address representation; Thanks to Samuel Merritt
* tpool: isolate internal socket from default timeout; Thanks to Alex Villacís Lasso
* wsgi: only skip Content-Type and Content-Length headers (GH-327)
* wsgi: 400 on blank Content-Length headers (GH-334)
* greenio: makefile related pypy socket ref counting
* ssl: Fix recv_into blocking when reading chunks of data
* websocket: support Gunicorn environ['gunicorn.socket']
0.19.0
======
* ssl: IMPORTANT DoS FIX do_handshake_connect=False in server accept(); Thanks to Garth Mollett

View File

@ -6,6 +6,7 @@ Module Reference
modules/backdoor
modules/corolocal
modules/dagpool
modules/debug
modules/db_pool
modules/event

View File

@ -0,0 +1,493 @@
:mod:`dagpool` -- Dependency-Driven Greenthreads
================================================
Rationale
*********
The dagpool module provides the :class:`DAGPool <eventlet.dagpool.DAGPool>`
class, which addresses situations in which the value produced by one
greenthread might be consumed by several others -- while at the same time a
consuming greenthread might depend on the output from several different
greenthreads.
If you have a tree with strict many-to-one dependencies -- each producer
greenthread provides results to exactly one consumer, though a given consumer
may depend on multiple producers -- that could be addressed by recursively
constructing a :class:`GreenPool <eventlet.greenpool.GreenPool>` of producers
for each consumer, then :meth:`waiting <eventlet.greenpool.GreenPool.waitall>`
for all producers.
If you have a tree with strict one-to-many dependencies -- each consumer
greenthread depends on exactly one producer, though a given producer may
provide results to multiple consumers -- that could be addressed by causing
each producer to finish by launching a :class:`GreenPool
<eventlet.greenpool.GreenPool>` of consumers.
But when you have many-to-many dependencies, a tree doesn't suffice. This is
known as a
`Directed Acyclic Graph <https://en.wikipedia.org/wiki/Directed_acyclic_graph>`_,
or DAG.
You might consider sorting the greenthreads into dependency order
(`topological sort <https://en.wikipedia.org/wiki/Topological_sorting>`_) and
launching them in a GreenPool. But the concurrency of the GreenPool must be
strictly constrained to ensure that no greenthread is launched before all its
upstream producers have completed -- and the appropriate pool size is
data-dependent. Only a pool of size 1 (serializing all the greenthreads)
guarantees that a topological sort will produce correct results.
Even if you do serialize all the greenthreads, how do you pass results from
each producer to all its consumers, which might start at very different points
in time?
One answer is to associate each greenthread with a distinct key, and store its
result in a common dict. Then each consumer greenthread can identify its
direct upstream producers by their keys, and find their results in that dict.
This is the essence of DAGPool.
A DAGPool instance owns a dict, and stores greenthread results in that dict.
You :meth:`spawn <eventlet.dagpool.DAGPool.spawn>` *all* greenthreads in the
DAG, specifying for each its own key -- the key with which its result will be
stored on completion -- plus the keys of the upstream producer greenthreads on
whose results it directly depends.
Keys need only be unique within the DAGPool instance; they need not be UUIDs.
A key can be any type that can be used as a dict key. String keys make it
easier to reason about a DAGPool's behavior, but are by no means required.
The DAGPool passes to each greenthread an iterable of (key, value) pairs.
The key in each pair is the key of one of the greenthread's specified upstream
producers; the value is the value returned by that producer greenthread. Pairs
are delivered in the order results become available; the consuming greenthread
blocks until the next result can be delivered.
Tutorial
*******
Example
-------
Consider a couple of programs in some compiled language that depend on a set
of precompiled libraries. Suppose every such build requires as input the
specific set of library builds on which it directly depends.
::
a zlib
| / |
|/ |
b c
| /|
| / |
| / |
|/ |
d e
We can't run the build for program d until we have the build results for both
b and c. We can't run the build for library b until we have build results for
a and zlib. We can, however, immediately run the builds for a and zlib.
So we can use a DAGPool instance to spawn greenthreads running a function such
as this:
::
def builder(key, upstream):
for libname, product in upstream:
# ... configure build for 'key' to use 'product' for 'libname'
# all upstream builds have completed
# ... run build for 'key'
return build_product_for_key
:meth:`spawn <eventlet.dagpool.DAGPool.spawn>` all these greenthreads:
::
pool = DAGPool()
# the upstream producer keys passed to spawn() can be from any iterable,
# including a generator
pool.spawn("d", ("b", "c"), builder)
pool.spawn("e", ["c"], builder)
pool.spawn("b", ("a", "zlib"), builder)
pool.spawn("c", ["zlib"], builder)
pool.spawn("a", (), builder)
As with :func:`eventlet.spawn() <eventlet.spawn>`, if you need to pass special
build flags to some set of builds, these can be passed as either positional or
keyword arguments:
::
def builder(key, upstream, cflags="", linkflags=""):
...
pool.spawn("d", ("b", "c"), builder, "-o2")
pool.spawn("e", ["c"], builder, linkflags="-pie")
However, if the arguments to each builder() call are uniform (as in the
original example), you could alternatively build a dict of the dependencies
and call :meth:`spawn_many() <eventlet.dagpool.DAGPool.spawn_many>`:
::
deps = dict(d=("b", "c"),
e=["c"],
b=("a", "zlib"),
c=["zlib"],
a=())
pool.spawn_many(deps, builder)
From outside the DAGPool, you can obtain the results for d and e (or in fact
for any of the build greenthreads) in any of several ways.
:meth:`pool.waitall() <eventlet.dagpool.DAGPool.waitall>` waits until the last of the spawned
greenthreads has completed, and returns a dict containing results for *all* of
them:
::
final = pool.waitall()
print("for d: {0}".format(final["d"]))
print("for e: {0}".format(final["e"]))
waitall() is an alias for :meth:`wait() <eventlet.dagpool.DAGPool.wait>` with no arguments:
::
final = pool.wait()
print("for d: {0}".format(final["d"]))
print("for e: {0}".format(final["e"]))
Or you can specifically wait for only the final programs:
::
final = pool.wait(["d", "e"])
The returned dict will contain only the specified keys. The keys may be passed
into wait() from any iterable, including a generator.
You can wait for any specified set of greenthreads; they need not be
topologically last:
::
# returns as soon as both a and zlib have returned results, regardless of
# what else is still running
leaves = pool.wait(["a", "zlib"])
Suppose you want to wait specifically for just *one* of the final programs:
::
final = pool.wait(["d"])
dprog = final["d"]
The above wait() call will return as soon as greenthread d returns a result --
regardless of whether greenthread e has finished.
:meth:`__getitem()__ <eventlet.dagpool.DAGPool.__getitem__>` is shorthand for
obtaining a single result:
::
# waits until greenthread d returns its result
dprog = pool["d"]
In contrast, :meth:`get() <eventlet.dagpool.DAGPool.get>` returns immediately,
whether or not a result is ready:
::
# returns immediately
if pool.get("d") is None:
...
Of course, your greenthread might not include an explicit return statement and
hence might implicitly return None. You might have to test some other value.
::
# returns immediately
if pool.get("d", "notdone") == "notdone":
...
Suppose you want to process each of the final programs in some way (upload
it?), but you don't want to have to wait until they've both finished. You
don't have to poll get() calls -- use :meth:`wait_each()
<eventlet.dagpool.DAGPool.wait_each>`:
::
for key, result in pool.wait_each(["d", "e"]):
# key will be d or e, in completion order
# process result...
As with :meth:`wait() <eventlet.dagpool.DAGPool.wait>`, if you omit the
argument to wait_each(), it delivers results for all the greenthreads of which
it's aware:
::
for key, result in pool.wait_each():
# key will be a, zlib, b, c, d, e, in whatever order each completes
# process its result...
Introspection
-------------
Let's say you have set up a :class:`DAGPool <eventlet.dagpool.DAGPool>` with
the dependencies shown above. To your consternation, your :meth:`waitall()
<eventlet.dagpool.DAGPool.waitall>` call does not return! The DAGPool instance
is stuck!
You could change waitall() to :meth:`wait_each()
<eventlet.dagpool.DAGPool.wait_each>`, and print each key as it becomes
available:
::
for key, result in pool.wait_each():
print("got result for {0}".format(key))
# ... process ...
Once the build for a has completed, this produces:
::
got result for a
and then stops. Hmm!
You can check the number of :meth:`running <eventlet.dagpool.DAGPool.running>`
greenthreads:
::
>>> print(pool.running())
4
and the number of :meth:`waiting <eventlet.dagpool.DAGPool.waiting>`
greenthreads:
::
>>> print(pool.waiting())
4
It's often more informative to ask *which* greenthreads are :meth:`still
running <eventlet.dagpool.DAGPool.running_keys>`:
::
>>> print(pool.running_keys())
('c', 'b', 'e', 'd')
but in this case, we already know a has completed.
We can ask for all available results:
::
>>> print(pool.keys())
('a',)
>>> print(pool.items())
(('a', result_from_a),)
The :meth:`keys() <eventlet.dagpool.DAGPool.keys>` and :meth:`items()
<eventlet.dagpool.DAGPool.items>` methods only return keys and items for
which results are actually available, reflecting the underlying dict.
But what's blocking the works? What are we :meth:`waiting for
<eventlet.dagpool.DAGPool.waiting_for>`?
::
>>> print(pool.waiting_for("d"))
set(['c', 'b'])
(waiting_for()'s optional argument is a *single* key.)
That doesn't help much yet...
::
>>> print(pool.waiting_for("b"))
set(['zlib'])
>>> print(pool.waiting_for("zlib"))
KeyError: 'zlib'
Aha! We forgot to even include the zlib build when we were originally
configuring this DAGPool!
(For non-interactive use, it would be more informative to omit waiting_for()'s
argument. This usage returns a dict indicating, for each greenthread key,
which other keys it's waiting for.)
::
from pprint import pprint
pprint(pool.waiting_for())
{'b': set(['zlib']), 'c': set(['zlib']), 'd': set(['b', 'c']), 'e': set(['c'])}
In this case, a reasonable fix would be to spawn the zlib greenthread:
::
pool.spawn("zlib", (), builder)
Even if this is the last method call on this DAGPool instance, it should
unblock all the rest of the DAGPool greenthreads.
Posting
-------
If we happen to have zlib build results in hand already, though, we could
instead :meth:`post() <eventlet.dagpool.DAGPool.post>` that result instead of
rebuilding the library:
::
pool.post("zlib", result_from_zlib)
This, too, should unblock the rest of the DAGPool greenthreads.
Preloading
----------
If rebuilding takes nontrivial realtime, it might be useful to record partial
results, so that in case of interruption you can restart from where you left
off rather than having to rebuild everything prior to that point.
You could iteratively :meth:`post() <eventlet.dagpool.DAGPool.post>` those
prior results into a new DAGPool instance; alternatively you can
:meth:`preload <eventlet.dagpool.DAGPool.__init__>` the :class:`DAGPool
<eventlet.dagpool.DAGPool>` from an existing dict:
::
pool = DAGPool(dict(a=result_from_a, zlib=result_from_zlib))
Any DAGPool greenthreads that depend on either a or zlib can immediately
consume those results.
It also works to construct DAGPool with an iterable of (key, result) pairs.
Exception Propagation
---------------------
But what if we spawn a zlib build that fails? Suppose the zlib greenthread
terminates with an exception? In that case none of b, c, d or e can proceed!
Nor do we want to wait forever for them.
::
dprog = pool["d"]
eventlet.dagpool.PropagateError: PropagateError(d): PropagateError: PropagateError(c): PropagateError: PropagateError(zlib): OriginalError
DAGPool provides a :class:`PropagateError <eventlet.dagpool.PropagateError>`
exception specifically to wrap such failures. If a DAGPool greenthread
terminates with an Exception subclass, the DAGPool wraps that exception in a
PropagateError instance whose *key* attribute is the key of the failing
greenthread and whose *exc* attribute is the exception that terminated it.
This PropagateError is stored as the result from that greenthread.
Attempting to consume the result from a greenthread for which a PropagateError
was stored raises that PropagateError.
::
pool["zlib"]
eventlet.dagpool.PropagateError: PropagateError(zlib): OriginalError
Thus, when greenthread c attempts to consume the result from zlib, the
PropagateError for zlib is raised. Unless the builder function for greenthread
c handles that PropagateError exception, that greenthread will itself
terminate. That PropagateError will be wrapped in another PropagateError whose
*key* attribute is c and whose *exc* attribute is the PropagateError for zlib.
Similarly, when greenthread d attempts to consume the result from c, the
PropagateError for c is raised. This in turn is wrapped in a PropagateError
whose *key* is d and whose *exc* is the PropagateError for c.
When someone attempts to consume the result from d, as shown above, the
PropagateError for d is raised.
You can programmatically chase the failure path to determine the original
failure if desired:
::
orig_err = err
key = "unknown"
while isinstance(orig_err, PropagateError):
key = orig_err.key
orig_err = orig_err.exc
Scanning for Success / Exceptions
---------------------------------
Exception propagation means that we neither perform useless builds nor wait for
results that will never arrive.
However, it does make it difficult to obtain *partial* results for builds that
*did* succeed.
For that you can call :meth:`wait_each_success()
<eventlet.dagpool.DAGPool.wait_each_success>`:
::
for key, result in pool.wait_each_success():
print("{0} succeeded".format(key))
# ... process result ...
a succeeded
Another problem is that although five different greenthreads failed in the
example, we only see one chain of failures. You can enumerate the bad news
with :meth:`wait_each_exception() <eventlet.dagpool.DAGPool.wait_each_exception>`:
::
for key, err in pool.wait_each_exception():
print("{0} failed with {1}".format(key, err.exc.__class__.__name__))
c failed with PropagateError
b failed with PropagateError
e failed with PropagateError
d failed with PropagateError
zlib failed with OriginalError
wait_each_exception() yields each PropagateError wrapper as if it were the
result, rather than raising it as an exception.
Notice that we print :code:`err.exc.__class__.__name__` because
:code:`err.__class__.__name__` is always PropagateError.
Both wait_each_success() and wait_each_exception() can accept an iterable of
keys to report:
::
for key, result in pool.wait_each_success(["d", "e"]):
print("{0} succeeded".format(key))
(no output)
for key, err in pool.wait_each_exception(["d", "e"]):
print("{0} failed with {1}".format(key, err.exc.__class__.__name__))
e failed with PropagateError
d failed with PropagateError
Both wait_each_success() and wait_each_exception() must wait until the
greenthreads for all specified keys (or all keys) have terminated, one way or
the other, because of course we can't know until then how to categorize each.
Module Contents
===============
.. automodule:: eventlet.dagpool
:members:

View File

@ -6,9 +6,7 @@
.. currentmodule:: eventlet.green.zmq
.. autofunction:: Context
.. autoclass:: _Context
.. autoclass:: Context
:show-inheritance:
.. automethod:: socket
@ -29,12 +27,12 @@
:mod:`pyzmq <zmq>` [1]_ Is a python binding to the C++ ØMQ [2]_ library written in Cython [3]_. The following is
auto generated :mod:`pyzmq's <zmq>` from documentation.
.. autoclass:: zmq.core.context.Context
.. autoclass:: zmq.Context
:members:
.. autoclass:: zmq.core.socket.Socket
.. autoclass:: zmq.Socket
.. autoclass:: zmq.core.poll.Poller
.. autoclass:: zmq.Poller
:members:

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Authors &mdash; Eventlet 0.19.0 documentation</title>
<title>Authors &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="History" href="history.html" />
<link rel="prev" title="eventlet.green.zmq ØMQ support" href="modules/zmq.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="modules/zmq.html" title="eventlet.green.zmq ØMQ support"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -196,6 +196,13 @@
<li>Collin Stocks, fixing eventlet.green.urllib2.urlopen() so it accepts cafile, capath, or cadefault arguments</li>
<li>Alexis Lee</li>
<li>Steven Erenst</li>
<li>Piët Delport</li>
<li>Alex Villacís Lasso</li>
<li>Yashwardhan Singh</li>
<li>Tim Burke</li>
<li>Ondřej Nový</li>
<li>Jarrod Johnson</li>
<li>Whitney Young</li>
</ul>
</div>
</div>
@ -263,7 +270,7 @@
<li class="right" >
<a href="modules/zmq.html" title="eventlet.green.zmq ØMQ support"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Basic Usage &mdash; Eventlet 0.19.0 documentation</title>
<title>Basic Usage &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="Design Patterns" href="design_patterns.html" />
<link rel="prev" title="Eventlet Documentation" href="index.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="index.html" title="Eventlet Documentation"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -303,7 +303,7 @@ connections until the existing ones complete.</p>
<li class="right" >
<a href="index.html" title="Eventlet Documentation"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>0.19.0 &mdash; Eventlet 0.19.0 documentation</title>
<title>0.20.0 &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
</head>
<body role="document">
<div class="related" role="navigation" aria-label="related navigation">
@ -35,7 +35,7 @@
<li class="right" >
<a href="py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -45,7 +45,30 @@
<div class="body" role="main">
<div class="section" id="id1">
<h1>0.19.0<a class="headerlink" href="#id1" title="Permalink to this headline"></a></h1>
<h1>0.20.0<a class="headerlink" href="#id1" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>IMPORTANT: removed select.poll() function</li>
<li>DNS resolving is always green with dnspython bundled in</li>
<li>greenio: only trampoline when we block</li>
<li>convenience: listen() sets SO_REUSEPORT when available; Thanks to Zhengwei Gao</li>
<li>ssl: Fix &#8220;TypeError: read() argument 2 must be read-write bytes-like object, not None&#8221;</li>
<li>greenio: _recv_loop behaviour with recv_into on closed sock</li>
<li>ipv6: getaddrinfo would fail with scope index</li>
<li>green.zmq: Support {send,recv}_{string,json,pyobj} wrappers</li>
<li>greendns: Return answers from /etc/hosts despite nameserver errors</li>
<li>patcher: fixed green existing locks fail (Python3)</li>
<li>Add DAGPool, a dependency-driven greenthread pool</li>
<li>wsgi: Unix socket address representation; Thanks to Samuel Merritt</li>
<li>tpool: isolate internal socket from default timeout; Thanks to Alex Villacís Lasso</li>
<li>wsgi: only skip Content-Type and Content-Length headers (GH-327)</li>
<li>wsgi: 400 on blank Content-Length headers (GH-334)</li>
<li>greenio: makefile related pypy socket ref counting</li>
<li>ssl: Fix recv_into blocking when reading chunks of data</li>
<li>websocket: support Gunicorn environ[&#8216;gunicorn.socket&#8217;]</li>
</ul>
</div>
<div class="section" id="id2">
<h1>0.19.0<a class="headerlink" href="#id2" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>ssl: IMPORTANT DoS FIX do_handshake_connect=False in server accept(); Thanks to Garth Mollett</li>
<li>patcher: patch existing threading locks; Thanks to Alexis Lee</li>
@ -56,36 +79,36 @@
<li>Minor grammatical improvements and typo fixes to the docs; Thanks to Steven Erenst</li>
</ul>
</div>
<div class="section" id="id2">
<h1>0.18.4<a class="headerlink" href="#id2" title="Permalink to this headline"></a></h1>
<div class="section" id="id3">
<h1>0.18.4<a class="headerlink" href="#id3" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>wsgi: change TCP_NODELAY to TCP_QUICKACK, ignore socket error when not available</li>
</ul>
</div>
<div class="section" id="id3">
<h1>0.18.3<a class="headerlink" href="#id3" title="Permalink to this headline"></a></h1>
<div class="section" id="id4">
<h1>0.18.3<a class="headerlink" href="#id4" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>wsgi: Use buffered writes - fixes partial socket.send without custom
writelines(); Github issue #295</li>
<li>wsgi: TCP_NODELAY enabled by default</li>
</ul>
</div>
<div class="section" id="id4">
<h1>0.18.2<a class="headerlink" href="#id4" title="Permalink to this headline"></a></h1>
<div class="section" id="id5">
<h1>0.18.2<a class="headerlink" href="#id5" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>wsgi: Fix data loss on partial writes (socket.send); Thanks to Jakub Stasiak</li>
</ul>
</div>
<div class="section" id="id5">
<h1>0.18.1<a class="headerlink" href="#id5" title="Permalink to this headline"></a></h1>
<div class="section" id="id6">
<h1>0.18.1<a class="headerlink" href="#id6" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>IMPORTANT: do not use Eventlet 0.18.0 and 0.18.1</li>
<li>patcher: Fix AttributeError in subprocess communicate()</li>
<li>greenio: Fix &#8220;TypeError: an integer is required&#8221; in sendto()</li>
</ul>
</div>
<div class="section" id="id6">
<h1>0.18.0<a class="headerlink" href="#id6" title="Permalink to this headline"></a></h1>
<div class="section" id="id7">
<h1>0.18.0<a class="headerlink" href="#id7" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>IMPORTANT: do not use Eventlet 0.18.0 and 0.18.1</li>
<li>greenio: Fixed a bug that could cause send() to start an endless loop on
@ -147,21 +170,21 @@ errors</p>
</li>
</ul>
</div>
<div class="section" id="id7">
<h1>0.17.4<a class="headerlink" href="#id7" title="Permalink to this headline"></a></h1>
<div class="section" id="id8">
<h1>0.17.4<a class="headerlink" href="#id8" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>ssl: incorrect initalization of default context; Thanks to stuart-mclaren</li>
</ul>
</div>
<div class="section" id="id8">
<h1>0.17.3<a class="headerlink" href="#id8" title="Permalink to this headline"></a></h1>
<div class="section" id="id9">
<h1>0.17.3<a class="headerlink" href="#id9" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>green.thread: Python3.3+ fixes; Thanks to Victor Stinner</li>
<li>Semaphore.acquire() accepts timeout=-1; Thanks to Victor Stinner</li>
</ul>
</div>
<div class="section" id="id9">
<h1>0.17.2<a class="headerlink" href="#id9" title="Permalink to this headline"></a></h1>
<div class="section" id="id10">
<h1>0.17.2<a class="headerlink" href="#id10" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>wsgi: Provide python logging compatibility; Thanks to Sean Dague</li>
<li>greendns: fix premature connection closing in DNS proxy; Thanks to Tim Simmons</li>
@ -170,14 +193,14 @@ errors</p>
<li>setup: tests.{isolated,manual} polluted top-level packages</li>
</ul>
</div>
<div class="section" id="id10">
<h1>0.17.1<a class="headerlink" href="#id10" title="Permalink to this headline"></a></h1>
<div class="section" id="id11">
<h1>0.17.1<a class="headerlink" href="#id11" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>greendns: fix dns.name import and Python3 compatibility</li>
</ul>
</div>
<div class="section" id="id11">
<h1>0.17<a class="headerlink" href="#id11" title="Permalink to this headline"></a></h1>
<div class="section" id="id12">
<h1>0.17<a class="headerlink" href="#id12" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Full Python3 compatibility; Thanks to Jakub Stasiak</li>
<li>greendns: IPv6 support, improved handling of /etc/hosts; Thanks to Floris Bruynooghe</li>
@ -188,14 +211,14 @@ errors</p>
<li>greenio: shutdown already closed sockets without error; Thanks to David Szotten</li>
</ul>
</div>
<div class="section" id="id12">
<h1>0.16.1<a class="headerlink" href="#id12" title="Permalink to this headline"></a></h1>
<div class="section" id="id13">
<h1>0.16.1<a class="headerlink" href="#id13" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Wheel build 0.16.0 incorrectly shipped removed module eventlet.util.</li>
</ul>
</div>
<div class="section" id="id13">
<h1>0.16.0<a class="headerlink" href="#id13" title="Permalink to this headline"></a></h1>
<div class="section" id="id14">
<h1>0.16.0<a class="headerlink" href="#id14" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Fix SSL socket wrapping and Python 2.7.9 compatibility; Thanks to Jakub Stasiak</li>
<li>Fix monkey_patch() on Python 3; Thanks to Victor Stinner</li>
@ -211,22 +234,22 @@ errors</p>
<li>tests: Fix timers not cleaned up on MySQL test skips; Thanks to Corey Wright</li>
</ul>
</div>
<div class="section" id="id14">
<h1>0.15.2<a class="headerlink" href="#id14" title="Permalink to this headline"></a></h1>
<div class="section" id="id15">
<h1>0.15.2<a class="headerlink" href="#id15" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>greenio: fixed memory leak, introduced in 0.15.1; Thanks to Michael Kerrin, Tushar Gohad</li>
<li>wsgi: Support optional headers w/ &#8220;100 Continue&#8221; responses; Thanks to Tushar Gohad</li>
</ul>
</div>
<div class="section" id="id15">
<h1>0.15.1<a class="headerlink" href="#id15" title="Permalink to this headline"></a></h1>
<div class="section" id="id16">
<h1>0.15.1<a class="headerlink" href="#id16" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>greenio: Fix second simultaneous read (parallel paramiko issue); Thanks to Jan Grant, Michael Kerrin</li>
<li>db_pool: customizable connection cleanup function; Thanks to Avery Fay</li>
</ul>
</div>
<div class="section" id="id16">
<h1>0.15<a class="headerlink" href="#id16" title="Permalink to this headline"></a></h1>
<div class="section" id="id17">
<h1>0.15<a class="headerlink" href="#id17" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Python3 compatibility &#8211; <strong>not ready yet</strong>; Thanks to Astrum Kuo, Davanum Srinivas, Jakub Stasiak, Victor Sergeyev</li>
<li>coros: remove Actor which was deprecated in 2010-01</li>
@ -241,8 +264,8 @@ errors</p>
<li>wsgi: capitalize_response_headers option</li>
</ul>
</div>
<div class="section" id="id17">
<h1>0.14<a class="headerlink" href="#id17" title="Permalink to this headline"></a></h1>
<div class="section" id="id18">
<h1>0.14<a class="headerlink" href="#id18" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>wsgi: handle connection socket timeouts; Thanks to Paul Oppenheim</li>
<li>wsgi: close timed out client connections</li>
@ -254,8 +277,8 @@ errors</p>
<li>wsgi: configurable socket_timeout</li>
</ul>
</div>
<div class="section" id="id18">
<h1>0.13<a class="headerlink" href="#id18" title="Permalink to this headline"></a></h1>
<div class="section" id="id19">
<h1>0.13<a class="headerlink" href="#id19" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>hubs: kqueue support! Thanks to YAMAMOTO Takashi, Edward George</li>
<li>greenio: Fix AttributeError on MacOSX; Bitbucket #136; Thanks to Derk Tegeler</li>
@ -272,8 +295,8 @@ errors</p>
<li>doc: hubs: Point to the correct function in exception message; Thanks to Floris Bruynooghe</li>
</ul>
</div>
<div class="section" id="id19">
<h1>0.12<a class="headerlink" href="#id19" title="Permalink to this headline"></a></h1>
<div class="section" id="id20">
<h1>0.12<a class="headerlink" href="#id20" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>zmq: Fix 100% busy CPU in idle after .bind(PUB) (thanks to Geoff Salmon)</li>
<li>greenio: Fix socket.settimeout() did not switch back to blocking mode (thanks to Peter Skirko)</li>
@ -283,16 +306,16 @@ errors</p>
<li>tests: Support libzmq 3.0 SNDHWM option (thanks to Geoff Salmon)</li>
</ul>
</div>
<div class="section" id="id20">
<h1>0.11<a class="headerlink" href="#id20" title="Permalink to this headline"></a></h1>
<div class="section" id="id21">
<h1>0.11<a class="headerlink" href="#id21" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>ssl: Fix 100% busy CPU in socket.sendall() (thanks to Raymon Lu)</li>
<li>zmq: Return linger argument to Socket.close() (thanks to Eric Windisch)</li>
<li>tests: SSL tests were always skipped due to bug in skip_if_no_ssl decorator</li>
</ul>
</div>
<div class="section" id="id21">
<h1>0.10<a class="headerlink" href="#id21" title="Permalink to this headline"></a></h1>
<div class="section" id="id22">
<h1>0.10<a class="headerlink" href="#id22" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>greenio: Fix relative seek() (thanks to AlanP)</li>
<li>db_pool: Fix pool.put() TypeError with min_size &gt; 1 (thanks to Jessica Qi)</li>
@ -310,8 +333,8 @@ errors</p>
<li>greenio: Remove deprecated GreenPipe.xreadlines() method, was broken anyway</li>
</ul>
</div>
<div class="section" id="id22">
<h1>0.9.17<a class="headerlink" href="#id22" title="Permalink to this headline"></a></h1>
<div class="section" id="id23">
<h1>0.9.17<a class="headerlink" href="#id23" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>ZeroMQ support calling send and recv from multiple greenthreads (thanks to Geoff Salmon)</li>
<li>SSL: unwrap() sends data, and so it needs trampolining (#104 thanks to Brandon Rhodes)</li>
@ -327,14 +350,14 @@ errors</p>
<li>wsgi: Configurable maximum URL length (thanks to Tomas Sedovic)</li>
</ul>
</div>
<div class="section" id="id23">
<h1>0.9.16<a class="headerlink" href="#id23" title="Permalink to this headline"></a></h1>
<div class="section" id="id24">
<h1>0.9.16<a class="headerlink" href="#id24" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>SO_REUSEADDR now correctly set.</li>
</ul>
</div>
<div class="section" id="id24">
<h1>0.9.15<a class="headerlink" href="#id24" title="Permalink to this headline"></a></h1>
<div class="section" id="id25">
<h1>0.9.15<a class="headerlink" href="#id25" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>ZeroMQ support without an explicit hub now implemented! Thanks to Zed Shaw for the patch.</li>
<li>zmq module supports the NOBLOCK flag, thanks to rfk. (#76)</li>
@ -346,8 +369,8 @@ errors</p>
<li>Timeouts raised within tpool.execute are propagated back to the caller (thanks again to redbo for being the squeaky wheel)</li>
</ul>
</div>
<div class="section" id="id25">
<h1>0.9.14<a class="headerlink" href="#id25" title="Permalink to this headline"></a></h1>
<div class="section" id="id26">
<h1>0.9.14<a class="headerlink" href="#id26" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Many fixes to the ZeroMQ hub, which now requires version 2.0.10 or later. Thanks to Ben Ford.</li>
<li>ZeroMQ hub no longer depends on pollhub, and thus works on Windows (thanks, Alexey Borzenkov)</li>
@ -361,8 +384,8 @@ errors</p>
<li>Documentation for eventlet.green.zmq, courtesy of Ben Ford</li>
</ul>
</div>
<div class="section" id="id26">
<h1>0.9.13<a class="headerlink" href="#id26" title="Permalink to this headline"></a></h1>
<div class="section" id="id27">
<h1>0.9.13<a class="headerlink" href="#id27" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>ZeroMQ hub, and eventlet.green.zmq make supersockets green. Thanks to Ben Ford!</li>
<li>eventlet.green.MySQLdb added. It&#8217;s an interface to MySQLdb that uses tpool to make it appear nonblocking</li>
@ -381,8 +404,8 @@ errors</p>
<li>Removed _main_wrapper from greenthread, thanks to Ambroff adding keyword arguments to switch() in 0.3!</li>
</ul>
</div>
<div class="section" id="id27">
<h1>0.9.12<a class="headerlink" href="#id27" title="Permalink to this headline"></a></h1>
<div class="section" id="id28">
<h1>0.9.12<a class="headerlink" href="#id28" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Eventlet no longer uses the Twisted hub if Twisted is imported &#8211; you must call eventlet.hubs.use_hub(&#8216;twistedr&#8217;) if you want to use it. This prevents strange race conditions for those who want to use both Twisted and Eventlet separately.</li>
<li>Removed circular import in twistedr.py</li>
@ -395,8 +418,8 @@ errors</p>
<li>Adding websocket.html to tarball so that you can run the examples without checking out the source</li>
</ul>
</div>
<div class="section" id="id28">
<h1>0.9.10<a class="headerlink" href="#id28" title="Permalink to this headline"></a></h1>
<div class="section" id="id29">
<h1>0.9.10<a class="headerlink" href="#id29" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Greendns: if dnspython is installed, Eventlet will automatically use it to provide non-blocking DNS queries. Set the environment variable &#8216;EVENTLET_NO_GREENDNS&#8217; if you don&#8217;t want greendns but have dnspython installed.</li>
<li>Full test suite passes on Python 2.7.</li>
@ -409,16 +432,16 @@ errors</p>
<li>Tweaked Timeout class to do something sensible when True is passed to the constructor</li>
</ul>
</div>
<div class="section" id="id29">
<h1>0.9.9<a class="headerlink" href="#id29" title="Permalink to this headline"></a></h1>
<div class="section" id="id30">
<h1>0.9.9<a class="headerlink" href="#id30" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>A fix for monkeypatching on systems with psycopg version 2.0.14.</li>
<li>Improved support for chunked transfers in wsgi, plus a bunch of tests from schmir (ported from gevent by redbo)</li>
<li>A fix for the twisted hub from Favo Yang</li>
</ul>
</div>
<div class="section" id="id30">
<h1>0.9.8<a class="headerlink" href="#id30" title="Permalink to this headline"></a></h1>
<div class="section" id="id31">
<h1>0.9.8<a class="headerlink" href="#id31" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Support for psycopg2&#8217;s asynchronous mode, from Daniele Varrazzo</li>
<li>websocket module is now part of core Eventlet with 100% unit test coverage thanks to Ben Ford. See its documentation at <a class="reference external" href="http://eventlet.net/doc/modules/websocket.html">http://eventlet.net/doc/modules/websocket.html</a></li>
@ -430,8 +453,8 @@ errors</p>
<li>Many bug fixes, major and minor.</li>
</ul>
</div>
<div class="section" id="id31">
<h1>0.9.7<a class="headerlink" href="#id31" title="Permalink to this headline"></a></h1>
<div class="section" id="id32">
<h1>0.9.7<a class="headerlink" href="#id32" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>GreenPipe is now a context manager (thanks, quad)</li>
<li>tpool.Proxy supports iterators properly</li>
@ -441,8 +464,8 @@ errors</p>
<li>multitudinous improvements in Py3k compatibility from amajorek</li>
</ul>
</div>
<div class="section" id="id32">
<h1>0.9.6<a class="headerlink" href="#id32" title="Permalink to this headline"></a></h1>
<div class="section" id="id33">
<h1>0.9.6<a class="headerlink" href="#id33" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>new EVENTLET_HUB environment variable allows you to select a hub without code</li>
<li>improved GreenSocket and GreenPipe compatibility with stdlib</li>
@ -461,8 +484,8 @@ errors</p>
<li>new eventlet.serve convenience function for easy TCP servers</li>
</ul>
</div>
<div class="section" id="id33">
<h1>0.9.5<a class="headerlink" href="#id33" title="Permalink to this headline"></a></h1>
<div class="section" id="id34">
<h1>0.9.5<a class="headerlink" href="#id34" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>support psycopg in db_pool</li>
<li>smart patcher that does the right patching when importing without needing to understand plumbing of patched module</li>
@ -485,8 +508,8 @@ errors</p>
<li>new convenience functions: eventlet.connect and eventlet.listen. Thanks, Sergey!</li>
</ul>
</div>
<div class="section" id="id34">
<h1>0.9.4<a class="headerlink" href="#id34" title="Permalink to this headline"></a></h1>
<div class="section" id="id35">
<h1>0.9.4<a class="headerlink" href="#id35" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Deprecated coros.Queue and coros.Channel (use queue.Queue instead)</li>
<li>Added putting and getting methods to queue.Queue.</li>
@ -495,8 +518,8 @@ errors</p>
<li>Bugfixes in wsgi, greenpool</li>
</ul>
</div>
<div class="section" id="id35">
<h1>0.9.3<a class="headerlink" href="#id35" title="Permalink to this headline"></a></h1>
<div class="section" id="id36">
<h1>0.9.3<a class="headerlink" href="#id36" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Moved primary api module to __init__ from api. It shouldn&#8217;t be necessary to import eventlet.api anymore; import eventlet should do the same job.</li>
<li>Proc module deprecated in favor of greenthread</li>
@ -522,16 +545,16 @@ errors</p>
<li>Removed saranwrap as an option for making db connections nonblocking in db_pool.</li>
</ul>
</div>
<div class="section" id="id36">
<h1>0.9.2<a class="headerlink" href="#id36" title="Permalink to this headline"></a></h1>
<div class="section" id="id37">
<h1>0.9.2<a class="headerlink" href="#id37" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Bugfix for wsgi.py where it was improperly expecting the environ variable to be a constant when passed to the application.</li>
<li>Tpool.py now passes its tests on Windows.</li>
<li>Fixed minor performance issue in wsgi.</li>
</ul>
</div>
<div class="section" id="id37">
<h1>0.9.1<a class="headerlink" href="#id37" title="Permalink to this headline"></a></h1>
<div class="section" id="id38">
<h1>0.9.1<a class="headerlink" href="#id38" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>PyOpenSSL is no longer required for Python 2.6: use the eventlet.green.ssl module. 2.5 and 2.4 still require PyOpenSSL.</li>
<li>Cleaned up the eventlet.green packages and their associated tests, this should result in fewer version-dependent bugs with these modules.</li>
@ -550,8 +573,8 @@ errors</p>
<li>Bug fixes in: wsgi.py, twistedr.py, poll.py, greenio.py, util.py, select.py, processes.py, selects.py</li>
</ul>
</div>
<div class="section" id="id38">
<h1>0.9.0<a class="headerlink" href="#id38" title="Permalink to this headline"></a></h1>
<div class="section" id="id39">
<h1>0.9.0<a class="headerlink" href="#id39" title="Permalink to this headline"></a></h1>
<ul>
<li><p class="first">Full-duplex sockets (simultaneous readers and writers in the same process).</p>
</li>
@ -571,23 +594,23 @@ errors</p>
</li>
</ul>
</div>
<div class="section" id="id39">
<h1>0.8.16<a class="headerlink" href="#id39" title="Permalink to this headline"></a></h1>
<div class="section" id="id40">
<h1>0.8.16<a class="headerlink" href="#id40" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>GreenSSLObject properly masks ZeroReturnErrors with an empty read; with unit test.</li>
<li>Fixed 2.6 SSL compatibility issue.</li>
</ul>
</div>
<div class="section" id="id40">
<h1>0.8.15<a class="headerlink" href="#id40" title="Permalink to this headline"></a></h1>
<div class="section" id="id41">
<h1>0.8.15<a class="headerlink" href="#id41" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>GreenSSL object no longer converts ZeroReturnErrors into empty reads, because that is more compatible with the underlying SSLConnection object.</li>
<li>Fixed issue caused by SIGCHLD handler in processes.py</li>
<li>Stopped supporting string exceptions in saranwrap and fixed a few test failures.</li>
</ul>
</div>
<div class="section" id="id41">
<h1>0.8.14<a class="headerlink" href="#id41" title="Permalink to this headline"></a></h1>
<div class="section" id="id42">
<h1>0.8.14<a class="headerlink" href="#id42" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>Fixed some more Windows compatibility problems, resolving EVT-37 :</li>
</ul>
@ -595,15 +618,15 @@ errors</p>
* waiting() method on Pool class, which was lost when the Pool implementation
replaced CoroutinePool.</p>
</div>
<div class="section" id="id42">
<h1>0.8.13<a class="headerlink" href="#id42" title="Permalink to this headline"></a></h1>
<div class="section" id="id43">
<h1>0.8.13<a class="headerlink" href="#id43" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>2.6 SSL compatibility patch by Marcus Cavanaugh.</li>
<li>Added greenlet and pyopenssl as dependencies in setup.py.</li>
</ul>
</div>
<div class="section" id="id43">
<h1>0.8.12<a class="headerlink" href="#id43" title="Permalink to this headline"></a></h1>
<div class="section" id="id44">
<h1>0.8.12<a class="headerlink" href="#id44" title="Permalink to this headline"></a></h1>
<ul class="simple">
<li>The ability to resize() pools of coroutines, which was lost when the</li>
</ul>
@ -616,8 +639,8 @@ like SSL.Connection objects.
* A small patch that makes Eventlet work on Windows. This is the first
release of Eventlet that works on Windows.</p>
</div>
<div class="section" id="id44">
<h1>0.8.11<a class="headerlink" href="#id44" title="Permalink to this headline"></a></h1>
<div class="section" id="id45">
<h1>0.8.11<a class="headerlink" href="#id45" title="Permalink to this headline"></a></h1>
<p>Eventlet can now run on top of twisted reactor. Twisted-based hub is enabled automatically if
twisted.internet.reactor is imported. It is also possible to &#8220;embed&#8221; eventlet into a twisted
application via eventlet.twistedutil.join_reactor. See the examples for details.</p>
@ -671,24 +694,24 @@ Thanks to Marcus Cavanaugh for pointing out some coros.queue(0) bugs.</p>
<p>Fix the libev hub to match libev&#8217;s callback signature. (Patch by grugq)</p>
<p>Add a backlog argument to api.tcp_listener (Patch by grugq)</p>
</div>
<div class="section" id="id45">
<h1>0.7.x<a class="headerlink" href="#id45" title="Permalink to this headline"></a></h1>
<div class="section" id="id46">
<h1>0.7.x<a class="headerlink" href="#id46" title="Permalink to this headline"></a></h1>
<p>Fix a major memory leak when using the libevent or libev hubs. Timers were not being removed from the hub after they fired. (Thanks Agusto Becciu and the grugq). Also, make it possible to call wrap_socket_with_coroutine_socket without using the threadpool to make dns operations non-blocking (Thanks the grugq).</p>
<p>It&#8217;s now possible to use eventlet&#8217;s SSL client to talk to eventlet&#8217;s SSL server. (Thanks to Ryan Williams)</p>
<p>Fixed a major CPU leak when using select hub. When adding a descriptor to the hub, entries were made in all three dictionaries, readers, writers, and exc, even if the callback is None. Thus every fd would be passed into all three lists when calling select regardless of whether there was a callback for that event or not. When reading the next request out of a keepalive socket, the socket would come back as ready for writing, the hub would notice the callback is None and ignore it, and then loop as fast as possible consuming CPU.</p>
</div>
<div class="section" id="id46">
<h1>0.6.x<a class="headerlink" href="#id46" title="Permalink to this headline"></a></h1>
<div class="section" id="id47">
<h1>0.6.x<a class="headerlink" href="#id47" title="Permalink to this headline"></a></h1>
<p>Fixes some long-standing bugs where sometimes failures in accept() or connect() would cause the coroutine that was waiting to be double-resumed, most often resulting in SwitchingToDeadGreenlet exceptions as well as weird tuple-unpacking exceptions in the CoroutinePool main loop.</p>
<p>0.6.1: Added eventlet.tpool.killall. Blocks until all of the threadpool threads have been told to exit and join()ed. Meant to be used to clean up the threadpool on exit or if calling execv. Used by Spawning.</p>
</div>
<div class="section" id="id47">
<h1>0.5.x<a class="headerlink" href="#id47" title="Permalink to this headline"></a></h1>
<div class="section" id="id48">
<h1>0.5.x<a class="headerlink" href="#id48" title="Permalink to this headline"></a></h1>
<p>&#8220;The Pycon 2008 Refactor&#8221;: The first release which incorporates libevent support. Also comes with significant refactoring and code cleanup, especially to the eventlet.wsgi http server. Docstring coverage is much higher and there is new extensive documentation: <a class="reference external" href="http://wiki.secondlife.com/wiki/Eventlet/Documentation">http://wiki.secondlife.com/wiki/Eventlet/Documentation</a></p>
<p>The point releases of 0.5.x fixed some bugs in the wsgi server, most notably handling of Transfer-Encoding: chunked; previously, it would happily send chunked encoding to clients which asked for HTTP/1.0, which isn&#8217;t legal.</p>
</div>
<div class="section" id="id48">
<h1>0.2<a class="headerlink" href="#id48" title="Permalink to this headline"></a></h1>
<div class="section" id="id49">
<h1>0.2<a class="headerlink" href="#id49" title="Permalink to this headline"></a></h1>
<p>Initial re-release of forked linden branch.</p>
</div>
@ -700,55 +723,56 @@ Thanks to Marcus Cavanaugh for pointing out some coros.queue(0) bugs.</p>
<div class="sphinxsidebarwrapper">
<h3><a href="index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference internal" href="#">0.19.0</a></li>
<li><a class="reference internal" href="#id2">0.18.4</a></li>
<li><a class="reference internal" href="#id3">0.18.3</a></li>
<li><a class="reference internal" href="#id4">0.18.2</a></li>
<li><a class="reference internal" href="#id5">0.18.1</a></li>
<li><a class="reference internal" href="#id6">0.18.0</a></li>
<li><a class="reference internal" href="#id7">0.17.4</a></li>
<li><a class="reference internal" href="#id8">0.17.3</a></li>
<li><a class="reference internal" href="#id9">0.17.2</a></li>
<li><a class="reference internal" href="#id10">0.17.1</a></li>
<li><a class="reference internal" href="#id11">0.17</a></li>
<li><a class="reference internal" href="#id12">0.16.1</a></li>
<li><a class="reference internal" href="#id13">0.16.0</a></li>
<li><a class="reference internal" href="#id14">0.15.2</a></li>
<li><a class="reference internal" href="#id15">0.15.1</a></li>
<li><a class="reference internal" href="#id16">0.15</a></li>
<li><a class="reference internal" href="#id17">0.14</a></li>
<li><a class="reference internal" href="#id18">0.13</a></li>
<li><a class="reference internal" href="#id19">0.12</a></li>
<li><a class="reference internal" href="#id20">0.11</a></li>
<li><a class="reference internal" href="#id21">0.10</a></li>
<li><a class="reference internal" href="#id22">0.9.17</a></li>
<li><a class="reference internal" href="#id23">0.9.16</a></li>
<li><a class="reference internal" href="#id24">0.9.15</a></li>
<li><a class="reference internal" href="#id25">0.9.14</a></li>
<li><a class="reference internal" href="#id26">0.9.13</a></li>
<li><a class="reference internal" href="#id27">0.9.12</a></li>
<li><a class="reference internal" href="#id28">0.9.10</a></li>
<li><a class="reference internal" href="#id29">0.9.9</a></li>
<li><a class="reference internal" href="#id30">0.9.8</a></li>
<li><a class="reference internal" href="#id31">0.9.7</a></li>
<li><a class="reference internal" href="#id32">0.9.6</a></li>
<li><a class="reference internal" href="#id33">0.9.5</a></li>
<li><a class="reference internal" href="#id34">0.9.4</a></li>
<li><a class="reference internal" href="#id35">0.9.3</a></li>
<li><a class="reference internal" href="#id36">0.9.2</a></li>
<li><a class="reference internal" href="#id37">0.9.1</a></li>
<li><a class="reference internal" href="#id38">0.9.0</a></li>
<li><a class="reference internal" href="#id39">0.8.16</a></li>
<li><a class="reference internal" href="#id40">0.8.15</a></li>
<li><a class="reference internal" href="#id41">0.8.14</a></li>
<li><a class="reference internal" href="#id42">0.8.13</a></li>
<li><a class="reference internal" href="#id43">0.8.12</a></li>
<li><a class="reference internal" href="#id44">0.8.11</a></li>
<li><a class="reference internal" href="#">0.20.0</a></li>
<li><a class="reference internal" href="#id2">0.19.0</a></li>
<li><a class="reference internal" href="#id3">0.18.4</a></li>
<li><a class="reference internal" href="#id4">0.18.3</a></li>
<li><a class="reference internal" href="#id5">0.18.2</a></li>
<li><a class="reference internal" href="#id6">0.18.1</a></li>
<li><a class="reference internal" href="#id7">0.18.0</a></li>
<li><a class="reference internal" href="#id8">0.17.4</a></li>
<li><a class="reference internal" href="#id9">0.17.3</a></li>
<li><a class="reference internal" href="#id10">0.17.2</a></li>
<li><a class="reference internal" href="#id11">0.17.1</a></li>
<li><a class="reference internal" href="#id12">0.17</a></li>
<li><a class="reference internal" href="#id13">0.16.1</a></li>
<li><a class="reference internal" href="#id14">0.16.0</a></li>
<li><a class="reference internal" href="#id15">0.15.2</a></li>
<li><a class="reference internal" href="#id16">0.15.1</a></li>
<li><a class="reference internal" href="#id17">0.15</a></li>
<li><a class="reference internal" href="#id18">0.14</a></li>
<li><a class="reference internal" href="#id19">0.13</a></li>
<li><a class="reference internal" href="#id20">0.12</a></li>
<li><a class="reference internal" href="#id21">0.11</a></li>
<li><a class="reference internal" href="#id22">0.10</a></li>
<li><a class="reference internal" href="#id23">0.9.17</a></li>
<li><a class="reference internal" href="#id24">0.9.16</a></li>
<li><a class="reference internal" href="#id25">0.9.15</a></li>
<li><a class="reference internal" href="#id26">0.9.14</a></li>
<li><a class="reference internal" href="#id27">0.9.13</a></li>
<li><a class="reference internal" href="#id28">0.9.12</a></li>
<li><a class="reference internal" href="#id29">0.9.10</a></li>
<li><a class="reference internal" href="#id30">0.9.9</a></li>
<li><a class="reference internal" href="#id31">0.9.8</a></li>
<li><a class="reference internal" href="#id32">0.9.7</a></li>
<li><a class="reference internal" href="#id33">0.9.6</a></li>
<li><a class="reference internal" href="#id34">0.9.5</a></li>
<li><a class="reference internal" href="#id35">0.9.4</a></li>
<li><a class="reference internal" href="#id36">0.9.3</a></li>
<li><a class="reference internal" href="#id37">0.9.2</a></li>
<li><a class="reference internal" href="#id38">0.9.1</a></li>
<li><a class="reference internal" href="#id39">0.9.0</a></li>
<li><a class="reference internal" href="#id40">0.8.16</a></li>
<li><a class="reference internal" href="#id41">0.8.15</a></li>
<li><a class="reference internal" href="#id42">0.8.14</a></li>
<li><a class="reference internal" href="#id43">0.8.13</a></li>
<li><a class="reference internal" href="#id44">0.8.12</a></li>
<li><a class="reference internal" href="#id45">0.8.11</a></li>
<li><a class="reference internal" href="#x">0.8.x</a></li>
<li><a class="reference internal" href="#id45">0.7.x</a></li>
<li><a class="reference internal" href="#id46">0.6.x</a></li>
<li><a class="reference internal" href="#id47">0.5.x</a></li>
<li><a class="reference internal" href="#id48">0.2</a></li>
<li><a class="reference internal" href="#id46">0.7.x</a></li>
<li><a class="reference internal" href="#id47">0.6.x</a></li>
<li><a class="reference internal" href="#id48">0.5.x</a></li>
<li><a class="reference internal" href="#id49">0.2</a></li>
</ul>
<div role="note" aria-label="source link">
@ -784,7 +808,7 @@ Thanks to Marcus Cavanaugh for pointing out some coros.queue(0) bugs.</p>
<li class="right" >
<a href="py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Design Patterns &mdash; Eventlet 0.19.0 documentation</title>
<title>Design Patterns &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="Greening The World" href="patching.html" />
<link rel="prev" title="Basic Usage" href="basic_usage.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="basic_usage.html" title="Basic Usage"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -204,7 +204,7 @@
<li class="right" >
<a href="basic_usage.html" title="Basic Usage"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Environment Variables &mdash; Eventlet 0.19.0 documentation</title>
<title>Environment Variables &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="Module Reference" href="modules.html" />
<link rel="prev" title="Testing Eventlet" href="testing.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="testing.html" title="Testing Eventlet"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -121,7 +121,7 @@ use, so any control of the pool size needs to happen before then.</div></blockqu
<li class="right" >
<a href="testing.html" title="Testing Eventlet"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Examples &mdash; Eventlet 0.19.0 documentation</title>
<title>Examples &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="Using SSL With Eventlet" href="ssl.html" />
<link rel="prev" title="Greening The World" href="patching.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="patching.html" title="Greening The World"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -608,7 +608,7 @@ implementation.</p>
<li class="right" >
<a href="patching.html" title="Greening The World"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -7,7 +7,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Index &mdash; Eventlet 0.19.0 documentation</title>
<title>Index &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -15,7 +15,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -24,7 +24,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
</head>
<body role="document">
<div class="related" role="navigation" aria-label="related navigation">
@ -36,7 +36,7 @@
<li class="right" >
<a href="py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -49,7 +49,8 @@
<h1 id="index">Index</h1>
<div class="genindex-jumpbox">
<a href="#A"><strong>A</strong></a>
<a href="#_"><strong>_</strong></a>
| <a href="#A"><strong>A</strong></a>
| <a href="#B"><strong>B</strong></a>
| <a href="#C"><strong>C</strong></a>
| <a href="#D"><strong>D</strong></a>
@ -61,6 +62,7 @@
| <a href="#J"><strong>J</strong></a>
| <a href="#K"><strong>K</strong></a>
| <a href="#L"><strong>L</strong></a>
| <a href="#M"><strong>M</strong></a>
| <a href="#N"><strong>N</strong></a>
| <a href="#P"><strong>P</strong></a>
| <a href="#Q"><strong>Q</strong></a>
@ -72,6 +74,22 @@
| <a href="#Z"><strong>Z</strong></a>
</div>
<h2 id="_">_</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.__getitem__">__getitem__() (eventlet.dagpool.DAGPool method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.__init__">__init__() (eventlet.dagpool.DAGPool method)</a>
</dt>
</dl></td>
</tr></table>
<h2 id="A">A</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
@ -123,10 +141,18 @@
<dt><a href="modules/db_pool.html#eventlet.db_pool.BaseConnectionPool">BaseConnectionPool (class in eventlet.db_pool)</a>
</dt>
<dt><a href="modules/db_pool.html#eventlet.db_pool.GenericConnectionWrapper.begin">begin() (eventlet.db_pool.GenericConnectionWrapper method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/db_pool.html#eventlet.db_pool.GenericConnectionWrapper.begin">begin() (eventlet.db_pool.GenericConnectionWrapper method)</a>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.bind">bind() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.bind_to_random_port">bind_to_random_port() (eventlet.green.zmq.Socket method)</a>
</dt>
@ -189,10 +215,18 @@
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.close">(eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/websocket.html#eventlet.websocket.WebSocket.close">(eventlet.websocket.WebSocket method)</a>
</dt>
</dl></dd>
<dt><a href="modules/dagpool.html#eventlet.dagpool.Collision">Collision</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
@ -209,6 +243,10 @@
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.connect">(eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="basic_usage.html#eventlet.connect">(in module eventlet)</a>
</dt>
@ -222,6 +260,16 @@
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Context">Context (class in eventlet.green.zmq)</a>
</dt>
<dd><dl>
<dt><a href="modules/zmq.html#zmq.Context">(class in zmq)</a>
</dt>
</dl></dd>
<dt><a href="modules/db_pool.html#eventlet.db_pool.RawConnectionPool.create">create() (eventlet.db_pool.RawConnectionPool method)</a>
</dt>
@ -250,12 +298,20 @@
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool">DAGPool (class in eventlet.dagpool)</a>
</dt>
<dt><a href="modules/db_pool.html#eventlet.db_pool.DatabaseConnector">DatabaseConnector (class in eventlet.db_pool)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.disconnect">disconnect() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/db_pool.html#eventlet.db_pool.GenericConnectionWrapper.dump_debug_info">dump_debug_info() (eventlet.db_pool.GenericConnectionWrapper method)</a>
</dt>
@ -298,6 +354,10 @@
</dt>
<dt><a href="modules/dagpool.html#module-eventlet.dagpool">eventlet.dagpool (module)</a>
</dt>
<dt><a href="modules/db_pool.html#module-eventlet.db_pool">eventlet.db_pool (module)</a>
</dt>
@ -310,6 +370,10 @@
</dt>
<dt><a href="modules/zmq.html#module-eventlet.green.zmq">eventlet.green.zmq (module)</a>
</dt>
<dt><a href="basic_usage.html#eventlet.GreenPile">eventlet.GreenPile (built-in class)</a>
</dt>
@ -333,12 +397,12 @@
<dt><a href="basic_usage.html#eventlet.import_patched">eventlet.import_patched() (built-in function)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="basic_usage.html#eventlet.monkey_patch">eventlet.monkey_patch() (built-in function)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="patching.html#eventlet.patcher.import_patched">eventlet.patcher.import_patched() (built-in function)</a>
</dt>
@ -456,15 +520,23 @@
</dt>
<dt><a href="modules/db_pool.html#eventlet.db_pool.BaseConnectionPool.get">get() (eventlet.db_pool.BaseConnectionPool method)</a>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.get">get() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dd><dl>
<dt><a href="modules/db_pool.html#eventlet.db_pool.BaseConnectionPool.get">(eventlet.db_pool.BaseConnectionPool method)</a>
</dt>
<dt><a href="modules/db_pool.html#eventlet.db_pool.DatabaseConnector.get">(eventlet.db_pool.DatabaseConnector method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.get">(eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/pools.html#eventlet.pools.Pool.get">(eventlet.pools.Pool method)</a>
</dt>
@ -482,13 +554,39 @@
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.get_hwm">get_hwm() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/corolocal.html#eventlet.corolocal.get_ident">get_ident() (in module eventlet.corolocal)</a>
</dt>
<dt><a href="modules/queue.html#eventlet.queue.LightQueue.get_nowait">get_nowait() (eventlet.queue.LightQueue method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.get_string">get_string() (eventlet.green.zmq.Socket method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/queue.html#eventlet.queue.LightQueue.get_nowait">get_nowait() (eventlet.queue.LightQueue method)</a>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.getsockopt">getsockopt() (eventlet.green.zmq.Socket method)</a>
</dt>
<dd><dl>
<dt><a href="modules/zmq.html#zmq.Context.getsockopt">(zmq.Context method)</a>
</dt>
</dl></dd>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.getsockopt_string">getsockopt_string() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.getsockopt_unicode">getsockopt_unicode() (eventlet.green.zmq.Socket method)</a>
</dt>
@ -535,6 +633,10 @@
<dt><a href="modules/debug.html#eventlet.debug.hub_timer_stacks">hub_timer_stacks() (in module eventlet.debug)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.hwm">hwm (eventlet.green.zmq.Socket attribute)</a>
</dt>
</dl></td>
</tr></table>
@ -549,6 +651,10 @@
<dt><a href="modules/db_pool.html#eventlet.db_pool.GenericConnectionWrapper.insert_id">insert_id() (eventlet.db_pool.GenericConnectionWrapper method)</a>
</dt>
<dt><a href="modules/zmq.html#zmq.Context.instance">instance() (zmq.Context class method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
@ -561,6 +667,10 @@
</dt>
</dl></dd>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.items">items() (eventlet.dagpool.DAGPool method)</a>
</dt>
</dl></td>
</tr></table>
@ -578,11 +688,21 @@
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/greenthread.html#eventlet.greenthread.GreenThread.kill">kill() (eventlet.greenthread.GreenThread method)</a>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.keys">keys() (eventlet.dagpool.DAGPool method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.kill">kill() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dd><dl>
<dt><a href="modules/greenthread.html#eventlet.greenthread.GreenThread.kill">(eventlet.greenthread.GreenThread method)</a>
</dt>
<dt><a href="modules/greenthread.html#eventlet.greenthread.kill">(in module eventlet.greenthread)</a>
</dt>
@ -632,6 +752,16 @@
</dl></td>
</tr></table>
<h2 id="M">M</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/zmq.html#zmq.Poller.modify">modify() (zmq.Poller method)</a>
</dt>
</dl></td>
</tr></table>
<h2 id="N">N</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
@ -654,6 +784,20 @@
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.poll">poll() (eventlet.green.zmq.Socket method)</a>
</dt>
<dd><dl>
<dt><a href="modules/zmq.html#zmq.Poller.poll">(zmq.Poller method)</a>
</dt>
</dl></dd>
<dt><a href="modules/zmq.html#zmq.Poller">Poller (class in zmq)</a>
</dt>
<dt><a href="modules/pools.html#eventlet.pools.Pool">Pool (class in eventlet.pools)</a>
</dt>
@ -662,12 +806,20 @@
</dt>
<dt><a href="modules/queue.html#eventlet.queue.PriorityQueue">PriorityQueue (class in eventlet.queue)</a>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.post">post() (eventlet.dagpool.DAGPool method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/queue.html#eventlet.queue.PriorityQueue">PriorityQueue (class in eventlet.queue)</a>
</dt>
<dt><a href="modules/dagpool.html#eventlet.dagpool.PropagateError">PropagateError</a>
</dt>
<dt><a href="threading.html#eventlet.tpool.Proxy">Proxy (class in eventlet.tpool)</a>
</dt>
@ -728,6 +880,36 @@
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.recv">recv() (eventlet.green.zmq.Socket method)</a>, <a href="modules/zmq.html#eventlet.green.zmq.Socket.recv">[1]</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.recv_json">recv_json() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.recv_multipart">recv_multipart() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.recv_pyobj">recv_pyobj() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.recv_string">recv_string() (eventlet.green.zmq.Socket method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.recv_unicode">recv_unicode() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#zmq.Poller.register">register() (zmq.Poller method)</a>
</dt>
<dt><a href="modules/semaphore.html#eventlet.semaphore.BoundedSemaphore.release">release() (eventlet.semaphore.BoundedSemaphore method)</a>
</dt>
@ -741,8 +923,6 @@
</dt>
</dl></dd>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/greenpool.html#eventlet.greenpool.GreenPool.resize">resize() (eventlet.greenpool.GreenPool method)</a>
</dt>
@ -762,7 +942,17 @@
</dt>
<dt><a href="modules/greenpool.html#eventlet.greenpool.GreenPool.running">running() (eventlet.greenpool.GreenPool method)</a>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.running">running() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dd><dl>
<dt><a href="modules/greenpool.html#eventlet.greenpool.GreenPool.running">(eventlet.greenpool.GreenPool method)</a>
</dt>
</dl></dd>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.running_keys">running_keys() (eventlet.dagpool.DAGPool method)</a>
</dt>
</dl></td>
@ -785,6 +975,10 @@
<dd><dl>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.send">(eventlet.green.zmq.Socket method)</a>, <a href="modules/zmq.html#eventlet.green.zmq.Socket.send">[1]</a>
</dt>
<dt><a href="modules/websocket.html#eventlet.websocket.WebSocket.send">(eventlet.websocket.WebSocket method)</a>
</dt>
@ -794,6 +988,26 @@
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.send_json">send_json() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.send_multipart">send_multipart() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.send_pyobj">send_pyobj() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.send_string">send_string() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.send_unicode">send_unicode() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="basic_usage.html#eventlet.serve">serve() (in module eventlet)</a>
</dt>
@ -806,10 +1020,18 @@
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.set">set() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/db_pool.html#eventlet.db_pool.GenericConnectionWrapper.set_character_set">set_character_set() (eventlet.db_pool.GenericConnectionWrapper method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.set_hwm">set_hwm() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/db_pool.html#eventlet.db_pool.GenericConnectionWrapper.set_server_option">set_server_option() (eventlet.db_pool.GenericConnectionWrapper method)</a>
</dt>
@ -818,6 +1040,30 @@
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.set_string">set_string() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.setsockopt">setsockopt() (eventlet.green.zmq.Socket method)</a>
</dt>
<dd><dl>
<dt><a href="modules/zmq.html#zmq.Context.setsockopt">(zmq.Context method)</a>
</dt>
</dl></dd>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.setsockopt_string">setsockopt_string() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.setsockopt_unicode">setsockopt_unicode() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/db_pool.html#eventlet.db_pool.GenericConnectionWrapper.show_warnings">show_warnings() (eventlet.db_pool.GenericConnectionWrapper method)</a>
</dt>
@ -825,18 +1071,40 @@
<dt><a href="modules/db_pool.html#eventlet.db_pool.GenericConnectionWrapper.shutdown">shutdown() (eventlet.db_pool.GenericConnectionWrapper method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/greenthread.html#eventlet.greenthread.sleep">sleep() (in module eventlet.greenthread)</a>
</dt>
<dt><a href="modules/greenpool.html#eventlet.greenpool.GreenPile.spawn">spawn() (eventlet.greenpool.GreenPile method)</a>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket">Socket (class in eventlet.green.zmq)</a>
</dt>
<dd><dl>
<dt><a href="modules/zmq.html#zmq.Socket">(class in zmq)</a>
</dt>
</dl></dd>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Context.socket">socket() (eventlet.green.zmq.Context method)</a>
</dt>
<dd><dl>
<dt><a href="modules/zmq.html#zmq.Context.socket">(zmq.Context method)</a>
</dt>
</dl></dd>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.spawn">spawn() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dd><dl>
<dt><a href="modules/greenpool.html#eventlet.greenpool.GreenPile.spawn">(eventlet.greenpool.GreenPile method)</a>
</dt>
<dt><a href="modules/greenpool.html#eventlet.greenpool.GreenPool.spawn">(eventlet.greenpool.GreenPool method)</a>
</dt>
@ -854,6 +1122,10 @@
</dt>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.spawn_many">spawn_many() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dt><a href="modules/greenpool.html#eventlet.greenpool.GreenPool.spawn_n">spawn_n() (eventlet.greenpool.GreenPool method)</a>
</dt>
@ -930,16 +1202,24 @@
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/zmq.html#eventlet.green.zmq.Socket.unbind">unbind() (eventlet.green.zmq.Socket method)</a>
</dt>
<dt><a href="modules/greenthread.html#eventlet.greenthread.GreenThread.unlink">unlink() (eventlet.greenthread.GreenThread method)</a>
</dt>
<dt><a href="modules/debug.html#eventlet.debug.unspew">unspew() (in module eventlet.debug)</a>
<dt><a href="modules/zmq.html#zmq.Poller.unregister">unregister() (zmq.Poller method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/debug.html#eventlet.debug.unspew">unspew() (in module eventlet.debug)</a>
</dt>
<dt><a href="modules/db_pool.html#eventlet.db_pool.GenericConnectionWrapper.use_result">use_result() (eventlet.db_pool.GenericConnectionWrapper method)</a>
</dt>
@ -950,11 +1230,15 @@
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/event.html#eventlet.event.Event.wait">wait() (eventlet.event.Event method)</a>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.wait">wait() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dd><dl>
<dt><a href="modules/event.html#eventlet.event.Event.wait">(eventlet.event.Event method)</a>
</dt>
<dt><a href="modules/greenthread.html#eventlet.greenthread.GreenThread.wait">(eventlet.greenthread.GreenThread method)</a>
</dt>
@ -964,25 +1248,51 @@
</dl></dd>
<dt><a href="modules/greenpool.html#eventlet.greenpool.GreenPool.waitall">waitall() (eventlet.greenpool.GreenPool method)</a>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.wait_each">wait_each() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dt><a href="modules/greenpool.html#eventlet.greenpool.GreenPool.waiting">waiting() (eventlet.greenpool.GreenPool method)</a>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.wait_each_exception">wait_each_exception() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.wait_each_success">wait_each_success() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.waitall">waitall() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dd><dl>
<dt><a href="modules/greenpool.html#eventlet.greenpool.GreenPool.waitall">(eventlet.greenpool.GreenPool method)</a>
</dt>
</dl></dd>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.waiting">waiting() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dd><dl>
<dt><a href="modules/greenpool.html#eventlet.greenpool.GreenPool.waiting">(eventlet.greenpool.GreenPool method)</a>
</dt>
<dt><a href="modules/pools.html#eventlet.pools.Pool.waiting">(eventlet.pools.Pool method)</a>
</dt>
</dl></dd>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/dagpool.html#eventlet.dagpool.DAGPool.waiting_for">waiting_for() (eventlet.dagpool.DAGPool method)</a>
</dt>
<dt><a href="modules/db_pool.html#eventlet.db_pool.GenericConnectionWrapper.warning_count">warning_count() (eventlet.db_pool.GenericConnectionWrapper method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="modules/websocket.html#eventlet.websocket.WebSocket">WebSocket (class in eventlet.websocket)</a>
</dt>
@ -1044,7 +1354,7 @@
<li class="right" >
<a href="py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>History &mdash; Eventlet 0.19.0 documentation</title>
<title>History &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="prev" title="Authors" href="authors.html" />
</head>
<body role="document">
@ -39,7 +39,7 @@
<li class="right" >
<a href="authors.html" title="Authors"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -103,7 +103,7 @@
<li class="right" >
<a href="authors.html" title="Authors"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Understanding Eventlet Hubs &mdash; Eventlet 0.19.0 documentation</title>
<title>Understanding Eventlet Hubs &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="Testing Eventlet" href="testing.html" />
<link rel="prev" title="Zeromq" href="zeromq.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="zeromq.html" title="Zeromq"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -207,7 +207,7 @@ unexpectedly without being deprecated first.</p>
<li class="right" >
<a href="zeromq.html" title="Zeromq"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Eventlet Documentation &mdash; Eventlet 0.19.0 documentation</title>
<title>Eventlet Documentation &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="#" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="#" />
<link rel="next" title="Basic Usage" href="basic_usage.html" />
</head>
<body role="document">
@ -39,7 +39,7 @@
<li class="right" >
<a href="basic_usage.html" title="Basic Usage"
accesskey="N">next</a> |</li>
<li class="nav-item nav-item-0"><a href="#">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="#">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -138,6 +138,8 @@
<li class="toctree-l1"><a class="reference internal" href="modules.html">Module Reference</a><ul>
<li class="toctree-l2"><a class="reference internal" href="modules/backdoor.html"><code class="docutils literal"><span class="pre">backdoor</span></code> &#8211; Python interactive interpreter within a running process</a></li>
<li class="toctree-l2"><a class="reference internal" href="modules/corolocal.html"><code class="docutils literal"><span class="pre">corolocal</span></code> &#8211; Coroutine local storage</a></li>
<li class="toctree-l2"><a class="reference internal" href="modules/dagpool.html"><code class="docutils literal"><span class="pre">dagpool</span></code> &#8211; Dependency-Driven Greenthreads</a></li>
<li class="toctree-l2"><a class="reference internal" href="modules/dagpool.html#module-eventlet.dagpool">Module Contents</a></li>
<li class="toctree-l2"><a class="reference internal" href="modules/debug.html"><code class="docutils literal"><span class="pre">debug</span></code> &#8211; Debugging tools for Eventlet</a></li>
<li class="toctree-l2"><a class="reference internal" href="modules/db_pool.html"><code class="docutils literal"><span class="pre">db_pool</span></code> &#8211; DBAPI 2 database connection pooling</a></li>
<li class="toctree-l2"><a class="reference internal" href="modules/event.html"><code class="docutils literal"><span class="pre">event</span></code> &#8211; Cross-greenthread primitive</a></li>
@ -233,7 +235,7 @@
<li class="right" >
<a href="basic_usage.html" title="Basic Usage"
>next</a> |</li>
<li class="nav-item nav-item-0"><a href="#">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="#">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Module Reference &mdash; Eventlet 0.19.0 documentation</title>
<title>Module Reference &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="backdoor Python interactive interpreter within a running process" href="modules/backdoor.html" />
<link rel="prev" title="Environment Variables" href="environment.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="environment.html" title="Environment Variables"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -58,6 +58,12 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="modules/backdoor.html"><code class="docutils literal"><span class="pre">backdoor</span></code> &#8211; Python interactive interpreter within a running process</a></li>
<li class="toctree-l1"><a class="reference internal" href="modules/corolocal.html"><code class="docutils literal"><span class="pre">corolocal</span></code> &#8211; Coroutine local storage</a></li>
<li class="toctree-l1"><a class="reference internal" href="modules/dagpool.html"><code class="docutils literal"><span class="pre">dagpool</span></code> &#8211; Dependency-Driven Greenthreads</a><ul>
<li class="toctree-l2"><a class="reference internal" href="modules/dagpool.html#rationale">Rationale</a></li>
<li class="toctree-l2"><a class="reference internal" href="modules/dagpool.html#tutorial">Tutorial</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="modules/dagpool.html#module-eventlet.dagpool">Module Contents</a></li>
<li class="toctree-l1"><a class="reference internal" href="modules/debug.html"><code class="docutils literal"><span class="pre">debug</span></code> &#8211; Debugging tools for Eventlet</a></li>
<li class="toctree-l1"><a class="reference internal" href="modules/db_pool.html"><code class="docutils literal"><span class="pre">db_pool</span></code> &#8211; DBAPI 2 database connection pooling</a><ul>
<li class="toctree-l2"><a class="reference internal" href="modules/db_pool.html#constructor-arguments">Constructor Arguments</a></li>
@ -135,7 +141,7 @@
<li class="right" >
<a href="environment.html" title="Environment Variables"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>backdoor Python interactive interpreter within a running process &mdash; Eventlet 0.19.0 documentation</title>
<title>backdoor Python interactive interpreter within a running process &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="corolocal Coroutine local storage" href="corolocal.html" />
<link rel="prev" title="Module Reference" href="../modules.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="../modules.html" title="Module Reference"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -146,7 +146,7 @@ variables in here.</p>
<li class="right" >
<a href="../modules.html" title="Module Reference"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>corolocal Coroutine local storage &mdash; Eventlet 0.19.0 documentation</title>
<title>corolocal Coroutine local storage &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,9 +23,9 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="debug Debugging tools for Eventlet" href="debug.html" />
<link rel="next" title="dagpool Dependency-Driven Greenthreads" href="dagpool.html" />
<link rel="prev" title="backdoor Python interactive interpreter within a running process" href="backdoor.html" />
</head>
<body role="document">
@ -39,12 +39,12 @@
<a href="../py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="right" >
<a href="debug.html" title="debug Debugging tools for Eventlet"
<a href="dagpool.html" title="dagpool Dependency-Driven Greenthreads"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="backdoor.html" title="backdoor Python interactive interpreter within a running process"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -79,8 +79,8 @@
<p class="topless"><a href="backdoor.html"
title="previous chapter"><code class="docutils literal"><span class="pre">backdoor</span></code> &#8211; Python interactive interpreter within a running process</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="debug.html"
title="next chapter"><code class="docutils literal"><span class="pre">debug</span></code> &#8211; Debugging tools for Eventlet</a></p>
<p class="topless"><a href="dagpool.html"
title="next chapter"><code class="docutils literal"><span class="pre">dagpool</span></code> &#8211; Dependency-Driven Greenthreads</a></p>
<div role="note" aria-label="source link">
<h3>This Page</h3>
<ul class="this-page-menu">
@ -115,12 +115,12 @@
<a href="../py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="right" >
<a href="debug.html" title="debug Debugging tools for Eventlet"
<a href="dagpool.html" title="dagpool Dependency-Driven Greenthreads"
>next</a> |</li>
<li class="right" >
<a href="backdoor.html" title="backdoor Python interactive interpreter within a running process"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

848
doc/modules/dagpool.html Normal file
View File

@ -0,0 +1,848 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>dagpool Dependency-Driven Greenthreads &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
};
</script>
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="debug Debugging tools for Eventlet" href="debug.html" />
<link rel="prev" title="corolocal Coroutine local storage" href="corolocal.html" />
</head>
<body role="document">
<div class="related" role="navigation" aria-label="related navigation">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="../py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="right" >
<a href="debug.html" title="debug Debugging tools for Eventlet"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="corolocal.html" title="corolocal Coroutine local storage"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body" role="main">
<div class="section" id="dagpool-dependency-driven-greenthreads">
<h1><code class="xref py py-mod docutils literal"><span class="pre">dagpool</span></code> &#8211; Dependency-Driven Greenthreads<a class="headerlink" href="#dagpool-dependency-driven-greenthreads" title="Permalink to this headline"></a></h1>
<div class="section" id="rationale">
<h2>Rationale<a class="headerlink" href="#rationale" title="Permalink to this headline"></a></h2>
<p>The dagpool module provides the <a class="reference internal" href="#eventlet.dagpool.DAGPool" title="eventlet.dagpool.DAGPool"><code class="xref py py-class docutils literal"><span class="pre">DAGPool</span></code></a>
class, which addresses situations in which the value produced by one
greenthread might be consumed by several others &#8211; while at the same time a
consuming greenthread might depend on the output from several different
greenthreads.</p>
<p>If you have a tree with strict many-to-one dependencies &#8211; each producer
greenthread provides results to exactly one consumer, though a given consumer
may depend on multiple producers &#8211; that could be addressed by recursively
constructing a <a class="reference internal" href="greenpool.html#eventlet.greenpool.GreenPool" title="eventlet.greenpool.GreenPool"><code class="xref py py-class docutils literal"><span class="pre">GreenPool</span></code></a> of producers
for each consumer, then <a class="reference internal" href="greenpool.html#eventlet.greenpool.GreenPool.waitall" title="eventlet.greenpool.GreenPool.waitall"><code class="xref py py-meth docutils literal"><span class="pre">waiting</span></code></a>
for all producers.</p>
<p>If you have a tree with strict one-to-many dependencies &#8211; each consumer
greenthread depends on exactly one producer, though a given producer may
provide results to multiple consumers &#8211; that could be addressed by causing
each producer to finish by launching a <a class="reference internal" href="greenpool.html#eventlet.greenpool.GreenPool" title="eventlet.greenpool.GreenPool"><code class="xref py py-class docutils literal"><span class="pre">GreenPool</span></code></a> of consumers.</p>
<p>But when you have many-to-many dependencies, a tree doesn&#8217;t suffice. This is
known as a
<a class="reference external" href="https://en.wikipedia.org/wiki/Directed_acyclic_graph">Directed Acyclic Graph</a>,
or DAG.</p>
<p>You might consider sorting the greenthreads into dependency order
(<a class="reference external" href="https://en.wikipedia.org/wiki/Topological_sorting">topological sort</a>) and
launching them in a GreenPool. But the concurrency of the GreenPool must be
strictly constrained to ensure that no greenthread is launched before all its
upstream producers have completed &#8211; and the appropriate pool size is
data-dependent. Only a pool of size 1 (serializing all the greenthreads)
guarantees that a topological sort will produce correct results.</p>
<p>Even if you do serialize all the greenthreads, how do you pass results from
each producer to all its consumers, which might start at very different points
in time?</p>
<p>One answer is to associate each greenthread with a distinct key, and store its
result in a common dict. Then each consumer greenthread can identify its
direct upstream producers by their keys, and find their results in that dict.</p>
<p>This is the essence of DAGPool.</p>
<p>A DAGPool instance owns a dict, and stores greenthread results in that dict.
You <a class="reference internal" href="#eventlet.dagpool.DAGPool.spawn" title="eventlet.dagpool.DAGPool.spawn"><code class="xref py py-meth docutils literal"><span class="pre">spawn</span></code></a> <em>all</em> greenthreads in the
DAG, specifying for each its own key &#8211; the key with which its result will be
stored on completion &#8211; plus the keys of the upstream producer greenthreads on
whose results it directly depends.</p>
<p>Keys need only be unique within the DAGPool instance; they need not be UUIDs.
A key can be any type that can be used as a dict key. String keys make it
easier to reason about a DAGPool&#8217;s behavior, but are by no means required.</p>
<p>The DAGPool passes to each greenthread an iterable of (key, value) pairs.
The key in each pair is the key of one of the greenthread&#8217;s specified upstream
producers; the value is the value returned by that producer greenthread. Pairs
are delivered in the order results become available; the consuming greenthread
blocks until the next result can be delivered.</p>
</div>
<div class="section" id="tutorial">
<h2>Tutorial<a class="headerlink" href="#tutorial" title="Permalink to this headline"></a></h2>
<div class="section" id="example">
<h3>Example<a class="headerlink" href="#example" title="Permalink to this headline"></a></h3>
<p>Consider a couple of programs in some compiled language that depend on a set
of precompiled libraries. Suppose every such build requires as input the
specific set of library builds on which it directly depends.</p>
<div class="highlight-python"><div class="highlight"><pre>a zlib
| / |
|/ |
b c
| /|
| / |
| / |
|/ |
d e
</pre></div>
</div>
<p>We can&#8217;t run the build for program d until we have the build results for both
b and c. We can&#8217;t run the build for library b until we have build results for
a and zlib. We can, however, immediately run the builds for a and zlib.</p>
<p>So we can use a DAGPool instance to spawn greenthreads running a function such
as this:</p>
<div class="highlight-python"><div class="highlight"><pre>def builder(key, upstream):
for libname, product in upstream:
# ... configure build for &#39;key&#39; to use &#39;product&#39; for &#39;libname&#39;
# all upstream builds have completed
# ... run build for &#39;key&#39;
return build_product_for_key
</pre></div>
</div>
<p><a class="reference internal" href="#eventlet.dagpool.DAGPool.spawn" title="eventlet.dagpool.DAGPool.spawn"><code class="xref py py-meth docutils literal"><span class="pre">spawn</span></code></a> all these greenthreads:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">pool</span> <span class="o">=</span> <span class="n">DAGPool</span><span class="p">()</span>
<span class="c1"># the upstream producer keys passed to spawn() can be from any iterable,</span>
<span class="c1"># including a generator</span>
<span class="n">pool</span><span class="o">.</span><span class="n">spawn</span><span class="p">(</span><span class="s2">&quot;d&quot;</span><span class="p">,</span> <span class="p">(</span><span class="s2">&quot;b&quot;</span><span class="p">,</span> <span class="s2">&quot;c&quot;</span><span class="p">),</span> <span class="n">builder</span><span class="p">)</span>
<span class="n">pool</span><span class="o">.</span><span class="n">spawn</span><span class="p">(</span><span class="s2">&quot;e&quot;</span><span class="p">,</span> <span class="p">[</span><span class="s2">&quot;c&quot;</span><span class="p">],</span> <span class="n">builder</span><span class="p">)</span>
<span class="n">pool</span><span class="o">.</span><span class="n">spawn</span><span class="p">(</span><span class="s2">&quot;b&quot;</span><span class="p">,</span> <span class="p">(</span><span class="s2">&quot;a&quot;</span><span class="p">,</span> <span class="s2">&quot;zlib&quot;</span><span class="p">),</span> <span class="n">builder</span><span class="p">)</span>
<span class="n">pool</span><span class="o">.</span><span class="n">spawn</span><span class="p">(</span><span class="s2">&quot;c&quot;</span><span class="p">,</span> <span class="p">[</span><span class="s2">&quot;zlib&quot;</span><span class="p">],</span> <span class="n">builder</span><span class="p">)</span>
<span class="n">pool</span><span class="o">.</span><span class="n">spawn</span><span class="p">(</span><span class="s2">&quot;a&quot;</span><span class="p">,</span> <span class="p">(),</span> <span class="n">builder</span><span class="p">)</span>
</pre></div>
</div>
<p>As with <a class="reference internal" href="../basic_usage.html#eventlet.spawn" title="eventlet.spawn"><code class="xref py py-func docutils literal"><span class="pre">eventlet.spawn()</span></code></a>, if you need to pass special
build flags to some set of builds, these can be passed as either positional or
keyword arguments:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="k">def</span> <span class="nf">builder</span><span class="p">(</span><span class="n">key</span><span class="p">,</span> <span class="n">upstream</span><span class="p">,</span> <span class="n">cflags</span><span class="o">=</span><span class="s2">&quot;&quot;</span><span class="p">,</span> <span class="n">linkflags</span><span class="o">=</span><span class="s2">&quot;&quot;</span><span class="p">):</span>
<span class="o">...</span>
<span class="n">pool</span><span class="o">.</span><span class="n">spawn</span><span class="p">(</span><span class="s2">&quot;d&quot;</span><span class="p">,</span> <span class="p">(</span><span class="s2">&quot;b&quot;</span><span class="p">,</span> <span class="s2">&quot;c&quot;</span><span class="p">),</span> <span class="n">builder</span><span class="p">,</span> <span class="s2">&quot;-o2&quot;</span><span class="p">)</span>
<span class="n">pool</span><span class="o">.</span><span class="n">spawn</span><span class="p">(</span><span class="s2">&quot;e&quot;</span><span class="p">,</span> <span class="p">[</span><span class="s2">&quot;c&quot;</span><span class="p">],</span> <span class="n">builder</span><span class="p">,</span> <span class="n">linkflags</span><span class="o">=</span><span class="s2">&quot;-pie&quot;</span><span class="p">)</span>
</pre></div>
</div>
<p>However, if the arguments to each builder() call are uniform (as in the
original example), you could alternatively build a dict of the dependencies
and call <a class="reference internal" href="#eventlet.dagpool.DAGPool.spawn_many" title="eventlet.dagpool.DAGPool.spawn_many"><code class="xref py py-meth docutils literal"><span class="pre">spawn_many()</span></code></a>:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">deps</span> <span class="o">=</span> <span class="nb">dict</span><span class="p">(</span><span class="n">d</span><span class="o">=</span><span class="p">(</span><span class="s2">&quot;b&quot;</span><span class="p">,</span> <span class="s2">&quot;c&quot;</span><span class="p">),</span>
<span class="n">e</span><span class="o">=</span><span class="p">[</span><span class="s2">&quot;c&quot;</span><span class="p">],</span>
<span class="n">b</span><span class="o">=</span><span class="p">(</span><span class="s2">&quot;a&quot;</span><span class="p">,</span> <span class="s2">&quot;zlib&quot;</span><span class="p">),</span>
<span class="n">c</span><span class="o">=</span><span class="p">[</span><span class="s2">&quot;zlib&quot;</span><span class="p">],</span>
<span class="n">a</span><span class="o">=</span><span class="p">())</span>
<span class="n">pool</span><span class="o">.</span><span class="n">spawn_many</span><span class="p">(</span><span class="n">deps</span><span class="p">,</span> <span class="n">builder</span><span class="p">)</span>
</pre></div>
</div>
<p>From outside the DAGPool, you can obtain the results for d and e (or in fact
for any of the build greenthreads) in any of several ways.</p>
<p><a class="reference internal" href="#eventlet.dagpool.DAGPool.waitall" title="eventlet.dagpool.DAGPool.waitall"><code class="xref py py-meth docutils literal"><span class="pre">pool.waitall()</span></code></a> waits until the last of the spawned
greenthreads has completed, and returns a dict containing results for <em>all</em> of
them:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">final</span> <span class="o">=</span> <span class="n">pool</span><span class="o">.</span><span class="n">waitall</span><span class="p">()</span>
<span class="k">print</span><span class="p">(</span><span class="s2">&quot;for d: {0}&quot;</span><span class="o">.</span><span class="n">format</span><span class="p">(</span><span class="n">final</span><span class="p">[</span><span class="s2">&quot;d&quot;</span><span class="p">]))</span>
<span class="k">print</span><span class="p">(</span><span class="s2">&quot;for e: {0}&quot;</span><span class="o">.</span><span class="n">format</span><span class="p">(</span><span class="n">final</span><span class="p">[</span><span class="s2">&quot;e&quot;</span><span class="p">]))</span>
</pre></div>
</div>
<p>waitall() is an alias for <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait" title="eventlet.dagpool.DAGPool.wait"><code class="xref py py-meth docutils literal"><span class="pre">wait()</span></code></a> with no arguments:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">final</span> <span class="o">=</span> <span class="n">pool</span><span class="o">.</span><span class="n">wait</span><span class="p">()</span>
<span class="k">print</span><span class="p">(</span><span class="s2">&quot;for d: {0}&quot;</span><span class="o">.</span><span class="n">format</span><span class="p">(</span><span class="n">final</span><span class="p">[</span><span class="s2">&quot;d&quot;</span><span class="p">]))</span>
<span class="k">print</span><span class="p">(</span><span class="s2">&quot;for e: {0}&quot;</span><span class="o">.</span><span class="n">format</span><span class="p">(</span><span class="n">final</span><span class="p">[</span><span class="s2">&quot;e&quot;</span><span class="p">]))</span>
</pre></div>
</div>
<p>Or you can specifically wait for only the final programs:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">final</span> <span class="o">=</span> <span class="n">pool</span><span class="o">.</span><span class="n">wait</span><span class="p">([</span><span class="s2">&quot;d&quot;</span><span class="p">,</span> <span class="s2">&quot;e&quot;</span><span class="p">])</span>
</pre></div>
</div>
<p>The returned dict will contain only the specified keys. The keys may be passed
into wait() from any iterable, including a generator.</p>
<p>You can wait for any specified set of greenthreads; they need not be
topologically last:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="c1"># returns as soon as both a and zlib have returned results, regardless of</span>
<span class="c1"># what else is still running</span>
<span class="n">leaves</span> <span class="o">=</span> <span class="n">pool</span><span class="o">.</span><span class="n">wait</span><span class="p">([</span><span class="s2">&quot;a&quot;</span><span class="p">,</span> <span class="s2">&quot;zlib&quot;</span><span class="p">])</span>
</pre></div>
</div>
<p>Suppose you want to wait specifically for just <em>one</em> of the final programs:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">final</span> <span class="o">=</span> <span class="n">pool</span><span class="o">.</span><span class="n">wait</span><span class="p">([</span><span class="s2">&quot;d&quot;</span><span class="p">])</span>
<span class="n">dprog</span> <span class="o">=</span> <span class="n">final</span><span class="p">[</span><span class="s2">&quot;d&quot;</span><span class="p">]</span>
</pre></div>
</div>
<p>The above wait() call will return as soon as greenthread d returns a result &#8211;
regardless of whether greenthread e has finished.</p>
<p><a class="reference internal" href="#eventlet.dagpool.DAGPool.__getitem__" title="eventlet.dagpool.DAGPool.__getitem__"><code class="xref py py-meth docutils literal"><span class="pre">__getitem()__</span></code></a> is shorthand for
obtaining a single result:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="c1"># waits until greenthread d returns its result</span>
<span class="n">dprog</span> <span class="o">=</span> <span class="n">pool</span><span class="p">[</span><span class="s2">&quot;d&quot;</span><span class="p">]</span>
</pre></div>
</div>
<p>In contrast, <a class="reference internal" href="#eventlet.dagpool.DAGPool.get" title="eventlet.dagpool.DAGPool.get"><code class="xref py py-meth docutils literal"><span class="pre">get()</span></code></a> returns immediately,
whether or not a result is ready:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="c1"># returns immediately</span>
<span class="k">if</span> <span class="n">pool</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s2">&quot;d&quot;</span><span class="p">)</span> <span class="ow">is</span> <span class="bp">None</span><span class="p">:</span>
<span class="o">...</span>
</pre></div>
</div>
<p>Of course, your greenthread might not include an explicit return statement and
hence might implicitly return None. You might have to test some other value.</p>
<div class="highlight-python"><div class="highlight"><pre><span class="c1"># returns immediately</span>
<span class="k">if</span> <span class="n">pool</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s2">&quot;d&quot;</span><span class="p">,</span> <span class="s2">&quot;notdone&quot;</span><span class="p">)</span> <span class="o">==</span> <span class="s2">&quot;notdone&quot;</span><span class="p">:</span>
<span class="o">...</span>
</pre></div>
</div>
<p>Suppose you want to process each of the final programs in some way (upload
it?), but you don&#8217;t want to have to wait until they&#8217;ve both finished. You
don&#8217;t have to poll get() calls &#8211; use <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each" title="eventlet.dagpool.DAGPool.wait_each"><code class="xref py py-meth docutils literal"><span class="pre">wait_each()</span></code></a>:</p>
<div class="highlight-python"><div class="highlight"><pre>for key, result in pool.wait_each([&quot;d&quot;, &quot;e&quot;]):
# key will be d or e, in completion order
# process result...
</pre></div>
</div>
<p>As with <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait" title="eventlet.dagpool.DAGPool.wait"><code class="xref py py-meth docutils literal"><span class="pre">wait()</span></code></a>, if you omit the
argument to wait_each(), it delivers results for all the greenthreads of which
it&#8217;s aware:</p>
<div class="highlight-python"><div class="highlight"><pre>for key, result in pool.wait_each():
# key will be a, zlib, b, c, d, e, in whatever order each completes
# process its result...
</pre></div>
</div>
</div>
<div class="section" id="introspection">
<h3>Introspection<a class="headerlink" href="#introspection" title="Permalink to this headline"></a></h3>
<p>Let&#8217;s say you have set up a <a class="reference internal" href="#eventlet.dagpool.DAGPool" title="eventlet.dagpool.DAGPool"><code class="xref py py-class docutils literal"><span class="pre">DAGPool</span></code></a> with
the dependencies shown above. To your consternation, your <a class="reference internal" href="#eventlet.dagpool.DAGPool.waitall" title="eventlet.dagpool.DAGPool.waitall"><code class="xref py py-meth docutils literal"><span class="pre">waitall()</span></code></a> call does not return! The DAGPool instance
is stuck!</p>
<p>You could change waitall() to <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each" title="eventlet.dagpool.DAGPool.wait_each"><code class="xref py py-meth docutils literal"><span class="pre">wait_each()</span></code></a>, and print each key as it becomes
available:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="k">for</span> <span class="n">key</span><span class="p">,</span> <span class="n">result</span> <span class="ow">in</span> <span class="n">pool</span><span class="o">.</span><span class="n">wait_each</span><span class="p">():</span>
<span class="k">print</span><span class="p">(</span><span class="s2">&quot;got result for {0}&quot;</span><span class="o">.</span><span class="n">format</span><span class="p">(</span><span class="n">key</span><span class="p">))</span>
<span class="c1"># ... process ...</span>
</pre></div>
</div>
<p>Once the build for a has completed, this produces:</p>
<div class="highlight-python"><div class="highlight"><pre>got result for a
</pre></div>
</div>
<p>and then stops. Hmm!</p>
<p>You can check the number of <a class="reference internal" href="#eventlet.dagpool.DAGPool.running" title="eventlet.dagpool.DAGPool.running"><code class="xref py py-meth docutils literal"><span class="pre">running</span></code></a>
greenthreads:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="k">print</span><span class="p">(</span><span class="n">pool</span><span class="o">.</span><span class="n">running</span><span class="p">())</span>
<span class="go">4</span>
</pre></div>
</div>
<p>and the number of <a class="reference internal" href="#eventlet.dagpool.DAGPool.waiting" title="eventlet.dagpool.DAGPool.waiting"><code class="xref py py-meth docutils literal"><span class="pre">waiting</span></code></a>
greenthreads:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="k">print</span><span class="p">(</span><span class="n">pool</span><span class="o">.</span><span class="n">waiting</span><span class="p">())</span>
<span class="go">4</span>
</pre></div>
</div>
<p>It&#8217;s often more informative to ask <em>which</em> greenthreads are <a class="reference internal" href="#eventlet.dagpool.DAGPool.running_keys" title="eventlet.dagpool.DAGPool.running_keys"><code class="xref py py-meth docutils literal"><span class="pre">still</span>
<span class="pre">running</span></code></a>:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="k">print</span><span class="p">(</span><span class="n">pool</span><span class="o">.</span><span class="n">running_keys</span><span class="p">())</span>
<span class="go">(&#39;c&#39;, &#39;b&#39;, &#39;e&#39;, &#39;d&#39;)</span>
</pre></div>
</div>
<p>but in this case, we already know a has completed.</p>
<p>We can ask for all available results:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="k">print</span><span class="p">(</span><span class="n">pool</span><span class="o">.</span><span class="n">keys</span><span class="p">())</span>
<span class="go">(&#39;a&#39;,)</span>
<span class="gp">&gt;&gt;&gt; </span><span class="k">print</span><span class="p">(</span><span class="n">pool</span><span class="o">.</span><span class="n">items</span><span class="p">())</span>
<span class="go">((&#39;a&#39;, result_from_a),)</span>
</pre></div>
</div>
<p>The <a class="reference internal" href="#eventlet.dagpool.DAGPool.keys" title="eventlet.dagpool.DAGPool.keys"><code class="xref py py-meth docutils literal"><span class="pre">keys()</span></code></a> and <a class="reference internal" href="#eventlet.dagpool.DAGPool.items" title="eventlet.dagpool.DAGPool.items"><code class="xref py py-meth docutils literal"><span class="pre">items()</span></code></a> methods only return keys and items for
which results are actually available, reflecting the underlying dict.</p>
<p>But what&#8217;s blocking the works? What are we <a class="reference internal" href="#eventlet.dagpool.DAGPool.waiting_for" title="eventlet.dagpool.DAGPool.waiting_for"><code class="xref py py-meth docutils literal"><span class="pre">waiting</span> <span class="pre">for</span></code></a>?</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="k">print</span><span class="p">(</span><span class="n">pool</span><span class="o">.</span><span class="n">waiting_for</span><span class="p">(</span><span class="s2">&quot;d&quot;</span><span class="p">))</span>
<span class="go">set([&#39;c&#39;, &#39;b&#39;])</span>
</pre></div>
</div>
<p>(waiting_for()&#8217;s optional argument is a <em>single</em> key.)</p>
<p>That doesn&#8217;t help much yet...</p>
<div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="k">print</span><span class="p">(</span><span class="n">pool</span><span class="o">.</span><span class="n">waiting_for</span><span class="p">(</span><span class="s2">&quot;b&quot;</span><span class="p">))</span>
<span class="go">set([&#39;zlib&#39;])</span>
<span class="gp">&gt;&gt;&gt; </span><span class="k">print</span><span class="p">(</span><span class="n">pool</span><span class="o">.</span><span class="n">waiting_for</span><span class="p">(</span><span class="s2">&quot;zlib&quot;</span><span class="p">))</span>
<span class="go">KeyError: &#39;zlib&#39;</span>
</pre></div>
</div>
<p>Aha! We forgot to even include the zlib build when we were originally
configuring this DAGPool!</p>
<p>(For non-interactive use, it would be more informative to omit waiting_for()&#8217;s
argument. This usage returns a dict indicating, for each greenthread key,
which other keys it&#8217;s waiting for.)</p>
<div class="highlight-python"><div class="highlight"><pre><span class="kn">from</span> <span class="nn">pprint</span> <span class="kn">import</span> <span class="n">pprint</span>
<span class="n">pprint</span><span class="p">(</span><span class="n">pool</span><span class="o">.</span><span class="n">waiting_for</span><span class="p">())</span>
<span class="p">{</span><span class="s1">&#39;b&#39;</span><span class="p">:</span> <span class="nb">set</span><span class="p">([</span><span class="s1">&#39;zlib&#39;</span><span class="p">]),</span> <span class="s1">&#39;c&#39;</span><span class="p">:</span> <span class="nb">set</span><span class="p">([</span><span class="s1">&#39;zlib&#39;</span><span class="p">]),</span> <span class="s1">&#39;d&#39;</span><span class="p">:</span> <span class="nb">set</span><span class="p">([</span><span class="s1">&#39;b&#39;</span><span class="p">,</span> <span class="s1">&#39;c&#39;</span><span class="p">]),</span> <span class="s1">&#39;e&#39;</span><span class="p">:</span> <span class="nb">set</span><span class="p">([</span><span class="s1">&#39;c&#39;</span><span class="p">])}</span>
</pre></div>
</div>
<p>In this case, a reasonable fix would be to spawn the zlib greenthread:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">pool</span><span class="o">.</span><span class="n">spawn</span><span class="p">(</span><span class="s2">&quot;zlib&quot;</span><span class="p">,</span> <span class="p">(),</span> <span class="n">builder</span><span class="p">)</span>
</pre></div>
</div>
<p>Even if this is the last method call on this DAGPool instance, it should
unblock all the rest of the DAGPool greenthreads.</p>
</div>
<div class="section" id="posting">
<h3>Posting<a class="headerlink" href="#posting" title="Permalink to this headline"></a></h3>
<p>If we happen to have zlib build results in hand already, though, we could
instead <a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post()</span></code></a> that result instead of
rebuilding the library:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">pool</span><span class="o">.</span><span class="n">post</span><span class="p">(</span><span class="s2">&quot;zlib&quot;</span><span class="p">,</span> <span class="n">result_from_zlib</span><span class="p">)</span>
</pre></div>
</div>
<p>This, too, should unblock the rest of the DAGPool greenthreads.</p>
</div>
<div class="section" id="preloading">
<h3>Preloading<a class="headerlink" href="#preloading" title="Permalink to this headline"></a></h3>
<p>If rebuilding takes nontrivial realtime, it might be useful to record partial
results, so that in case of interruption you can restart from where you left
off rather than having to rebuild everything prior to that point.</p>
<p>You could iteratively <a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post()</span></code></a> those
prior results into a new DAGPool instance; alternatively you can
<a class="reference internal" href="#eventlet.dagpool.DAGPool.__init__" title="eventlet.dagpool.DAGPool.__init__"><code class="xref py py-meth docutils literal"><span class="pre">preload</span></code></a> the <a class="reference internal" href="#eventlet.dagpool.DAGPool" title="eventlet.dagpool.DAGPool"><code class="xref py py-class docutils literal"><span class="pre">DAGPool</span></code></a> from an existing dict:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">pool</span> <span class="o">=</span> <span class="n">DAGPool</span><span class="p">(</span><span class="nb">dict</span><span class="p">(</span><span class="n">a</span><span class="o">=</span><span class="n">result_from_a</span><span class="p">,</span> <span class="n">zlib</span><span class="o">=</span><span class="n">result_from_zlib</span><span class="p">))</span>
</pre></div>
</div>
<p>Any DAGPool greenthreads that depend on either a or zlib can immediately
consume those results.</p>
<p>It also works to construct DAGPool with an iterable of (key, result) pairs.</p>
</div>
<div class="section" id="exception-propagation">
<h3>Exception Propagation<a class="headerlink" href="#exception-propagation" title="Permalink to this headline"></a></h3>
<p>But what if we spawn a zlib build that fails? Suppose the zlib greenthread
terminates with an exception? In that case none of b, c, d or e can proceed!
Nor do we want to wait forever for them.</p>
<div class="highlight-python"><div class="highlight"><pre>dprog = pool[&quot;d&quot;]
eventlet.dagpool.PropagateError: PropagateError(d): PropagateError: PropagateError(c): PropagateError: PropagateError(zlib): OriginalError
</pre></div>
</div>
<p>DAGPool provides a <a class="reference internal" href="#eventlet.dagpool.PropagateError" title="eventlet.dagpool.PropagateError"><code class="xref py py-class docutils literal"><span class="pre">PropagateError</span></code></a>
exception specifically to wrap such failures. If a DAGPool greenthread
terminates with an Exception subclass, the DAGPool wraps that exception in a
PropagateError instance whose <em>key</em> attribute is the key of the failing
greenthread and whose <em>exc</em> attribute is the exception that terminated it.
This PropagateError is stored as the result from that greenthread.</p>
<p>Attempting to consume the result from a greenthread for which a PropagateError
was stored raises that PropagateError.</p>
<div class="highlight-python"><div class="highlight"><pre>pool[&quot;zlib&quot;]
eventlet.dagpool.PropagateError: PropagateError(zlib): OriginalError
</pre></div>
</div>
<p>Thus, when greenthread c attempts to consume the result from zlib, the
PropagateError for zlib is raised. Unless the builder function for greenthread
c handles that PropagateError exception, that greenthread will itself
terminate. That PropagateError will be wrapped in another PropagateError whose
<em>key</em> attribute is c and whose <em>exc</em> attribute is the PropagateError for zlib.</p>
<p>Similarly, when greenthread d attempts to consume the result from c, the
PropagateError for c is raised. This in turn is wrapped in a PropagateError
whose <em>key</em> is d and whose <em>exc</em> is the PropagateError for c.</p>
<p>When someone attempts to consume the result from d, as shown above, the
PropagateError for d is raised.</p>
<p>You can programmatically chase the failure path to determine the original
failure if desired:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">orig_err</span> <span class="o">=</span> <span class="n">err</span>
<span class="n">key</span> <span class="o">=</span> <span class="s2">&quot;unknown&quot;</span>
<span class="k">while</span> <span class="nb">isinstance</span><span class="p">(</span><span class="n">orig_err</span><span class="p">,</span> <span class="n">PropagateError</span><span class="p">):</span>
<span class="n">key</span> <span class="o">=</span> <span class="n">orig_err</span><span class="o">.</span><span class="n">key</span>
<span class="n">orig_err</span> <span class="o">=</span> <span class="n">orig_err</span><span class="o">.</span><span class="n">exc</span>
</pre></div>
</div>
</div>
<div class="section" id="scanning-for-success-exceptions">
<h3>Scanning for Success / Exceptions<a class="headerlink" href="#scanning-for-success-exceptions" title="Permalink to this headline"></a></h3>
<p>Exception propagation means that we neither perform useless builds nor wait for
results that will never arrive.</p>
<p>However, it does make it difficult to obtain <em>partial</em> results for builds that
<em>did</em> succeed.</p>
<p>For that you can call <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each_success" title="eventlet.dagpool.DAGPool.wait_each_success"><code class="xref py py-meth docutils literal"><span class="pre">wait_each_success()</span></code></a>:</p>
<div class="highlight-python"><div class="highlight"><pre>for key, result in pool.wait_each_success():
print(&quot;{0} succeeded&quot;.format(key))
# ... process result ...
a succeeded
</pre></div>
</div>
<p>Another problem is that although five different greenthreads failed in the
example, we only see one chain of failures. You can enumerate the bad news
with <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each_exception" title="eventlet.dagpool.DAGPool.wait_each_exception"><code class="xref py py-meth docutils literal"><span class="pre">wait_each_exception()</span></code></a>:</p>
<div class="highlight-python"><div class="highlight"><pre>for key, err in pool.wait_each_exception():
print(&quot;{0} failed with {1}&quot;.format(key, err.exc.__class__.__name__))
c failed with PropagateError
b failed with PropagateError
e failed with PropagateError
d failed with PropagateError
zlib failed with OriginalError
</pre></div>
</div>
<p>wait_each_exception() yields each PropagateError wrapper as if it were the
result, rather than raising it as an exception.</p>
<p>Notice that we print <code class="code docutils literal"><span class="pre">err.exc.__class__.__name__</span></code> because
<code class="code docutils literal"><span class="pre">err.__class__.__name__</span></code> is always PropagateError.</p>
<p>Both wait_each_success() and wait_each_exception() can accept an iterable of
keys to report:</p>
<div class="highlight-python"><div class="highlight"><pre>for key, result in pool.wait_each_success([&quot;d&quot;, &quot;e&quot;]):
print(&quot;{0} succeeded&quot;.format(key))
(no output)
for key, err in pool.wait_each_exception([&quot;d&quot;, &quot;e&quot;]):
print(&quot;{0} failed with {1}&quot;.format(key, err.exc.__class__.__name__))
e failed with PropagateError
d failed with PropagateError
</pre></div>
</div>
<p>Both wait_each_success() and wait_each_exception() must wait until the
greenthreads for all specified keys (or all keys) have terminated, one way or
the other, because of course we can&#8217;t know until then how to categorize each.</p>
</div>
</div>
</div>
<div class="section" id="module-eventlet.dagpool">
<span id="module-contents"></span><h1>Module Contents<a class="headerlink" href="#module-eventlet.dagpool" title="Permalink to this headline"></a></h1>
<dl class="exception">
<dt id="eventlet.dagpool.Collision">
<em class="property">exception </em><code class="descclassname">eventlet.dagpool.</code><code class="descname">Collision</code><a class="headerlink" href="#eventlet.dagpool.Collision" title="Permalink to this definition"></a></dt>
<dd><p>DAGPool raises Collision when you try to launch two greenthreads with the
same key, or post() a result for a key corresponding to a greenthread, or
post() twice for the same key. As with KeyError, str(collision) names the
key in question.</p>
</dd></dl>
<dl class="class">
<dt id="eventlet.dagpool.DAGPool">
<em class="property">class </em><code class="descclassname">eventlet.dagpool.</code><code class="descname">DAGPool</code><span class="sig-paren">(</span><em>preload={}</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool" title="Permalink to this definition"></a></dt>
<dd><p>A DAGPool is a pool that constrains greenthreads, not by max concurrency,
but by data dependencies.</p>
<p>This is a way to implement general DAG dependencies. A simple dependency
tree (flowing in either direction) can straightforwardly be implemented
using recursion and (e.g.)
<code class="xref py py-meth docutils literal"><span class="pre">GreenThread.imap()</span></code>.
What gets complicated is when a given node depends on several other nodes
as well as contributing to several other nodes.</p>
<p>With DAGPool, you concurrently launch all applicable greenthreads; each
will proceed as soon as it has all required inputs. The DAG is implicit in
which items are required by each greenthread.</p>
<p>Each greenthread is launched in a DAGPool with a key: any value that can
serve as a Python dict key. The caller also specifies an iterable of other
keys on which this greenthread depends. This iterable may be empty.</p>
<p>The greenthread callable must accept (key, results), where:</p>
<dl class="docutils">
<dt>key</dt>
<dd>is its own key</dd>
<dt>results</dt>
<dd>is an iterable of (key, value) pairs.</dd>
</dl>
<p>A newly-launched DAGPool greenthread is entered immediately, and can
perform any necessary setup work. At some point it will iterate over the
(key, value) pairs from the passed &#8216;results&#8217; iterable. Doing so blocks the
greenthread until a value is available for each of the keys specified in
its initial dependencies iterable. These (key, value) pairs are delivered
in chronological order, <em>not</em> the order in which they are initially
specified: each value will be delivered as soon as it becomes available.</p>
<p>The value returned by a DAGPool greenthread becomes the value for its
key, which unblocks any other greenthreads waiting on that key.</p>
<p>If a DAGPool greenthread terminates with an exception instead of returning
a value, attempting to retrieve the value raises <a class="reference internal" href="#eventlet.dagpool.PropagateError" title="eventlet.dagpool.PropagateError"><code class="xref py py-class docutils literal"><span class="pre">PropagateError</span></code></a>,
which binds the key of the original greenthread and the original
exception. Unless the greenthread attempting to retrieve the value handles
PropagateError, that exception will in turn be wrapped in a PropagateError
of its own, and so forth. The code that ultimately handles PropagateError
can follow the chain of PropagateError.exc attributes to discover the flow
of that exception through the DAG of greenthreads.</p>
<p>External greenthreads may also interact with a DAGPool. See <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each" title="eventlet.dagpool.DAGPool.wait_each"><code class="xref py py-meth docutils literal"><span class="pre">wait_each()</span></code></a>,
<a class="reference internal" href="#eventlet.dagpool.DAGPool.waitall" title="eventlet.dagpool.DAGPool.waitall"><code class="xref py py-meth docutils literal"><span class="pre">waitall()</span></code></a>, <a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post()</span></code></a>.</p>
<p>It is not recommended to constrain external DAGPool producer greenthreads
in a <a class="reference internal" href="greenpool.html#eventlet.greenpool.GreenPool" title="eventlet.greenpool.GreenPool"><code class="xref py py-class docutils literal"><span class="pre">GreenPool</span></code></a>: it may be hard to
provably avoid deadlock.</p>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.__init__">
<code class="descname">__init__</code><span class="sig-paren">(</span><em>preload={}</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.__init__" title="Permalink to this definition"></a></dt>
<dd><p>DAGPool can be prepopulated with an initial dict or iterable of (key,
value) pairs. These (key, value) pairs are of course immediately
available for any greenthread that depends on any of those keys.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.__getitem__">
<code class="descname">__getitem__</code><span class="sig-paren">(</span><em>key</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.__getitem__" title="Permalink to this definition"></a></dt>
<dd><p>__getitem__(key) (aka dagpool[key]) blocks until <em>key</em> has a value,
then delivers that value.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.get">
<code class="descname">get</code><span class="sig-paren">(</span><em>key</em>, <em>default=None</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.get" title="Permalink to this definition"></a></dt>
<dd><p>get() returns the value for <em>key</em>. If <em>key</em> does not yet have a value,
get() returns <em>default</em>.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.items">
<code class="descname">items</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.items" title="Permalink to this definition"></a></dt>
<dd><p>Return a snapshot tuple of currently-available (key, value) pairs.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.keys">
<code class="descname">keys</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.keys" title="Permalink to this definition"></a></dt>
<dd><p>Return a snapshot tuple of keys for which we currently have values.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.kill">
<code class="descname">kill</code><span class="sig-paren">(</span><em>key</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.kill" title="Permalink to this definition"></a></dt>
<dd><p>Kill the greenthread that was spawned with the specified <em>key</em>.</p>
<p>If no such greenthread was spawned, raise KeyError.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.post">
<code class="descname">post</code><span class="sig-paren">(</span><em>key</em>, <em>value</em>, <em>replace=False</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.post" title="Permalink to this definition"></a></dt>
<dd><p>post(key, value) stores the passed <em>value</em> for the passed <em>key</em>. It
then causes each greenthread blocked on its results iterable, or on
<a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each" title="eventlet.dagpool.DAGPool.wait_each"><code class="xref py py-meth docutils literal"><span class="pre">wait_each(keys)</span></code></a>, to check for new values.
A waiting greenthread might not literally resume on every single
post() of a relevant key, but the first post() of a relevant key
ensures that it will resume eventually, and when it does it will catch
up with all relevant post() calls.</p>
<p>Calling post(key, value) when there is a running greenthread with that
same <em>key</em> raises <a class="reference internal" href="#eventlet.dagpool.Collision" title="eventlet.dagpool.Collision"><code class="xref py py-class docutils literal"><span class="pre">Collision</span></code></a>. If you must post(key, value) instead of
letting the greenthread run to completion, you must first call
<a class="reference internal" href="#eventlet.dagpool.DAGPool.kill" title="eventlet.dagpool.DAGPool.kill"><code class="xref py py-meth docutils literal"><span class="pre">kill(key)</span></code></a>.</p>
<p>The DAGPool implicitly post()s the return value from each of its
greenthreads. But a greenthread may explicitly post() a value for its
own key, which will cause its return value to be discarded.</p>
<p>Calling post(key, value, replace=False) (the default <em>replace</em>) when a
value for that key has already been posted, by any means, raises
<a class="reference internal" href="#eventlet.dagpool.Collision" title="eventlet.dagpool.Collision"><code class="xref py py-class docutils literal"><span class="pre">Collision</span></code></a>.</p>
<p>Calling post(key, value, replace=True) when a value for that key has
already been posted, by any means, replaces the previously-stored
value. However, that may make it complicated to reason about the
behavior of greenthreads waiting on that key.</p>
<p>After a post(key, value1) followed by post(key, value2, replace=True),
it is unspecified which pending <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each" title="eventlet.dagpool.DAGPool.wait_each"><code class="xref py py-meth docutils literal"><span class="pre">wait_each([key...])</span></code></a>
calls (or greenthreads iterating over <em>results</em> involving that key)
will observe <em>value1</em> versus <em>value2</em>. It is guaranteed that
subsequent wait_each([key...]) calls (or greenthreads spawned after
that point) will observe <em>value2</em>.</p>
<p>A successful call to
post(key, <a class="reference internal" href="#eventlet.dagpool.PropagateError" title="eventlet.dagpool.PropagateError"><code class="xref py py-class docutils literal"><span class="pre">PropagateError(key,</span> <span class="pre">ExceptionSubclass)</span></code></a>)
ensures that any subsequent attempt to retrieve that key&#8217;s value will
raise that PropagateError instance.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.running">
<code class="descname">running</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.running" title="Permalink to this definition"></a></dt>
<dd><p>Return number of running DAGPool greenthreads. This includes
greenthreads blocked while iterating through their <em>results</em> iterable,
that is, greenthreads waiting on values from other keys.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.running_keys">
<code class="descname">running_keys</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.running_keys" title="Permalink to this definition"></a></dt>
<dd><p>Return keys for running DAGPool greenthreads. This includes
greenthreads blocked while iterating through their <em>results</em> iterable,
that is, greenthreads waiting on values from other keys.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.spawn">
<code class="descname">spawn</code><span class="sig-paren">(</span><em>key</em>, <em>depends</em>, <em>function</em>, <em>*args</em>, <em>**kwds</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.spawn" title="Permalink to this definition"></a></dt>
<dd><p>Launch the passed <em>function(key, results, ...)</em> as a greenthread,
passing it:</p>
<ul class="simple">
<li>the specified <em>key</em></li>
<li>an iterable of (key, value) pairs</li>
<li>whatever other positional args or keywords you specify.</li>
</ul>
<p>Iterating over the <em>results</em> iterable behaves like calling
<a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each" title="eventlet.dagpool.DAGPool.wait_each"><code class="xref py py-meth docutils literal"><span class="pre">wait_each(depends)</span></code></a>.</p>
<p>Returning from <em>function()</em> behaves like
<a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post(key,</span> <span class="pre">return_value)</span></code></a>.</p>
<p>If <em>function()</em> terminates with an exception, that exception is wrapped
in <a class="reference internal" href="#eventlet.dagpool.PropagateError" title="eventlet.dagpool.PropagateError"><code class="xref py py-class docutils literal"><span class="pre">PropagateError</span></code></a> with the greenthread&#8217;s <em>key</em> and (effectively) posted
as the value for that key. Attempting to retrieve that value will
raise that PropagateError.</p>
<p>Thus, if the greenthread with key &#8216;a&#8217; terminates with an exception,
and greenthread &#8216;b&#8217; depends on &#8216;a&#8217;, when greenthread &#8216;b&#8217; attempts to
iterate through its <em>results</em> argument, it will encounter
PropagateError. So by default, an uncaught exception will propagate
through all the downstream dependencies.</p>
<p>If you pass <a class="reference internal" href="#eventlet.dagpool.DAGPool.spawn" title="eventlet.dagpool.DAGPool.spawn"><code class="xref py py-meth docutils literal"><span class="pre">spawn()</span></code></a> a key already passed to spawn() or <a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post()</span></code></a>, spawn()
raises <a class="reference internal" href="#eventlet.dagpool.Collision" title="eventlet.dagpool.Collision"><code class="xref py py-class docutils literal"><span class="pre">Collision</span></code></a>.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.spawn_many">
<code class="descname">spawn_many</code><span class="sig-paren">(</span><em>depends</em>, <em>function</em>, <em>*args</em>, <em>**kwds</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.spawn_many" title="Permalink to this definition"></a></dt>
<dd><p>spawn_many() accepts a single <em>function</em> whose parameters are the same
as for <a class="reference internal" href="#eventlet.dagpool.DAGPool.spawn" title="eventlet.dagpool.DAGPool.spawn"><code class="xref py py-meth docutils literal"><span class="pre">spawn()</span></code></a>.</p>
<p>The difference is that spawn_many() accepts a dependency dict
<em>depends</em>. A new greenthread is spawned for each key in the dict. That
dict key&#8217;s value should be an iterable of other keys on which this
greenthread depends.</p>
<p>If the <em>depends</em> dict contains any key already passed to <a class="reference internal" href="#eventlet.dagpool.DAGPool.spawn" title="eventlet.dagpool.DAGPool.spawn"><code class="xref py py-meth docutils literal"><span class="pre">spawn()</span></code></a>
or <a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post()</span></code></a>, spawn_many() raises <a class="reference internal" href="#eventlet.dagpool.Collision" title="eventlet.dagpool.Collision"><code class="xref py py-class docutils literal"><span class="pre">Collision</span></code></a>. It is
indeterminate how many of the other keys in <em>depends</em> will have
successfully spawned greenthreads.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.wait">
<code class="descname">wait</code><span class="sig-paren">(</span><em>keys=&lt;object object&gt;</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.wait" title="Permalink to this definition"></a></dt>
<dd><p><em>keys</em> is an optional iterable of keys. If you omit the argument, it
waits for all the keys from <a class="reference internal" href="#eventlet.dagpool.DAGPool" title="eventlet.dagpool.DAGPool"><code class="xref py py-class docutils literal"><span class="pre">preload</span> <span class="pre">data</span></code></a>, from
<a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post()</span></code></a> calls and from <a class="reference internal" href="#eventlet.dagpool.DAGPool.spawn" title="eventlet.dagpool.DAGPool.spawn"><code class="xref py py-meth docutils literal"><span class="pre">spawn()</span></code></a> calls: in other words, all
the keys of which this DAGPool is aware.</p>
<p>wait() blocks the calling greenthread until all of the relevant keys
have values. wait() returns a dict whose keys are the relevant keys,
and whose values come from the <em>preload</em> data, from values returned by
DAGPool greenthreads or from <a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post()</span></code></a> calls.</p>
<p>If a DAGPool greenthread terminates with an exception, wait() will
raise <a class="reference internal" href="#eventlet.dagpool.PropagateError" title="eventlet.dagpool.PropagateError"><code class="xref py py-class docutils literal"><span class="pre">PropagateError</span></code></a> wrapping that exception. If more than
one greenthread terminates with an exception, it is indeterminate
which one wait() will raise.</p>
<p>If an external greenthread posts a <a class="reference internal" href="#eventlet.dagpool.PropagateError" title="eventlet.dagpool.PropagateError"><code class="xref py py-class docutils literal"><span class="pre">PropagateError</span></code></a> instance,
wait() will raise that PropagateError. If more than one greenthread
posts PropagateError, it is indeterminate which one wait() will raise.</p>
<p>See also <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each_success" title="eventlet.dagpool.DAGPool.wait_each_success"><code class="xref py py-meth docutils literal"><span class="pre">wait_each_success()</span></code></a>, <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each_exception" title="eventlet.dagpool.DAGPool.wait_each_exception"><code class="xref py py-meth docutils literal"><span class="pre">wait_each_exception()</span></code></a>.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.wait_each">
<code class="descname">wait_each</code><span class="sig-paren">(</span><em>keys=&lt;object object&gt;</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.wait_each" title="Permalink to this definition"></a></dt>
<dd><p><em>keys</em> is an optional iterable of keys. If you omit the argument, it
waits for all the keys from <a class="reference internal" href="#eventlet.dagpool.DAGPool" title="eventlet.dagpool.DAGPool"><code class="xref py py-class docutils literal"><span class="pre">preload</span> <span class="pre">data</span></code></a>, from
<a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post()</span></code></a> calls and from <a class="reference internal" href="#eventlet.dagpool.DAGPool.spawn" title="eventlet.dagpool.DAGPool.spawn"><code class="xref py py-meth docutils literal"><span class="pre">spawn()</span></code></a> calls: in other words, all
the keys of which this DAGPool is aware.</p>
<p>wait_each() is a generator producing (key, value) pairs as a value
becomes available for each requested key. wait_each() blocks the
calling greenthread until the next value becomes available. If the
DAGPool was prepopulated with values for any of the relevant keys, of
course those can be delivered immediately without waiting.</p>
<p>Delivery order is intentionally decoupled from the initial sequence of
keys: each value is delivered as soon as it becomes available. If
multiple keys are available at the same time, wait_each() delivers
each of the ready ones in arbitrary order before blocking again.</p>
<p>The DAGPool does not distinguish between a value returned by one of
its own greenthreads and one provided by a <a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post()</span></code></a> call or <em>preload</em> data.</p>
<p>The wait_each() generator terminates (raises StopIteration) when all
specified keys have been delivered. Thus, typical usage might be:</p>
<div class="highlight-python"><div class="highlight"><pre>for key, value in dagpool.wait_each(keys):
# process this ready key and value
# continue processing now that we&#39;ve gotten values for all keys
</pre></div>
</div>
<p>By implication, if you pass wait_each() an empty iterable of keys, it
returns immediately without yielding anything.</p>
<p>If the value to be delivered is a <a class="reference internal" href="#eventlet.dagpool.PropagateError" title="eventlet.dagpool.PropagateError"><code class="xref py py-class docutils literal"><span class="pre">PropagateError</span></code></a> exception object, the
generator raises that PropagateError instead of yielding it.</p>
<p>See also <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each_success" title="eventlet.dagpool.DAGPool.wait_each_success"><code class="xref py py-meth docutils literal"><span class="pre">wait_each_success()</span></code></a>, <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each_exception" title="eventlet.dagpool.DAGPool.wait_each_exception"><code class="xref py py-meth docutils literal"><span class="pre">wait_each_exception()</span></code></a>.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.wait_each_exception">
<code class="descname">wait_each_exception</code><span class="sig-paren">(</span><em>keys=&lt;object object&gt;</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.wait_each_exception" title="Permalink to this definition"></a></dt>
<dd><p>wait_each_exception() filters results so that only exceptions are
yielded. Not every provided (or defaulted) key will necessarily be
represented, though naturally the generator will not finish until
all have completed.</p>
<p>Unlike other DAGPool methods, wait_each_exception() simply yields
<a class="reference internal" href="#eventlet.dagpool.PropagateError" title="eventlet.dagpool.PropagateError"><code class="xref py py-class docutils literal"><span class="pre">PropagateError</span></code></a> instances as values rather than raising them.</p>
<p>In all other respects, wait_each_exception() behaves like <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each" title="eventlet.dagpool.DAGPool.wait_each"><code class="xref py py-meth docutils literal"><span class="pre">wait_each()</span></code></a>.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.wait_each_success">
<code class="descname">wait_each_success</code><span class="sig-paren">(</span><em>keys=&lt;object object&gt;</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.wait_each_success" title="Permalink to this definition"></a></dt>
<dd><p>wait_each_success() filters results so that only success values are
yielded. In other words, unlike <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each" title="eventlet.dagpool.DAGPool.wait_each"><code class="xref py py-meth docutils literal"><span class="pre">wait_each()</span></code></a>, wait_each_success()
will not raise <a class="reference internal" href="#eventlet.dagpool.PropagateError" title="eventlet.dagpool.PropagateError"><code class="xref py py-class docutils literal"><span class="pre">PropagateError</span></code></a>. Not every provided (or
defaulted) key will necessarily be represented, though naturally the
generator will not finish until all have completed.</p>
<p>In all other respects, wait_each_success() behaves like <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each" title="eventlet.dagpool.DAGPool.wait_each"><code class="xref py py-meth docutils literal"><span class="pre">wait_each()</span></code></a>.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.waitall">
<code class="descname">waitall</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.waitall" title="Permalink to this definition"></a></dt>
<dd><p>waitall() blocks the calling greenthread until there is a value for
every DAGPool greenthread launched by <a class="reference internal" href="#eventlet.dagpool.DAGPool.spawn" title="eventlet.dagpool.DAGPool.spawn"><code class="xref py py-meth docutils literal"><span class="pre">spawn()</span></code></a>. It returns a dict
containing all <a class="reference internal" href="#eventlet.dagpool.DAGPool" title="eventlet.dagpool.DAGPool"><code class="xref py py-class docutils literal"><span class="pre">preload</span> <span class="pre">data</span></code></a>, all data from
<a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post()</span></code></a> and all values returned by spawned greenthreads.</p>
<p>See also <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait" title="eventlet.dagpool.DAGPool.wait"><code class="xref py py-meth docutils literal"><span class="pre">wait()</span></code></a>.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.waiting">
<code class="descname">waiting</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.waiting" title="Permalink to this definition"></a></dt>
<dd><p>Return number of waiting DAGPool greenthreads, that is, greenthreads
still waiting on values from other keys. This explicitly does <em>not</em>
include external greenthreads waiting on <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait" title="eventlet.dagpool.DAGPool.wait"><code class="xref py py-meth docutils literal"><span class="pre">wait()</span></code></a>,
<a class="reference internal" href="#eventlet.dagpool.DAGPool.waitall" title="eventlet.dagpool.DAGPool.waitall"><code class="xref py py-meth docutils literal"><span class="pre">waitall()</span></code></a>, <a class="reference internal" href="#eventlet.dagpool.DAGPool.wait_each" title="eventlet.dagpool.DAGPool.wait_each"><code class="xref py py-meth docutils literal"><span class="pre">wait_each()</span></code></a>.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.dagpool.DAGPool.waiting_for">
<code class="descname">waiting_for</code><span class="sig-paren">(</span><em>key=&lt;object object&gt;</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.DAGPool.waiting_for" title="Permalink to this definition"></a></dt>
<dd><p>waiting_for(key) returns a set() of the keys for which the DAGPool
greenthread spawned with that <em>key</em> is still waiting. If you pass a
<em>key</em> for which no greenthread was spawned, waiting_for() raises
KeyError.</p>
<p>waiting_for() without argument returns a dict. Its keys are the keys
of DAGPool greenthreads still waiting on one or more values. In the
returned dict, the value of each such key is the set of other keys for
which that greenthread is still waiting.</p>
<p>This method allows diagnosing a &#8220;hung&#8221; DAGPool. If certain
greenthreads are making no progress, it&#8217;s possible that they are
waiting on keys for which there is no greenthread and no <a class="reference internal" href="#eventlet.dagpool.DAGPool.post" title="eventlet.dagpool.DAGPool.post"><code class="xref py py-meth docutils literal"><span class="pre">post()</span></code></a> data.</p>
</dd></dl>
</dd></dl>
<dl class="exception">
<dt id="eventlet.dagpool.PropagateError">
<em class="property">exception </em><code class="descclassname">eventlet.dagpool.</code><code class="descname">PropagateError</code><span class="sig-paren">(</span><em>key</em>, <em>exc</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.dagpool.PropagateError" title="Permalink to this definition"></a></dt>
<dd><p>When a DAGPool greenthread terminates with an exception instead of
returning a result, attempting to retrieve its value raises
PropagateError.</p>
<p>Attributes:</p>
<dl class="docutils">
<dt>key</dt>
<dd>the key of the greenthread which raised the exception</dd>
<dt>exc</dt>
<dd>the exception object raised by the greenthread</dd>
</dl>
</dd></dl>
</div>
</div>
</div>
</div>
<div class="sphinxsidebar" role="navigation" aria-label="main navigation">
<div class="sphinxsidebarwrapper">
<h3><a href="../index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference internal" href="#"><code class="docutils literal"><span class="pre">dagpool</span></code> &#8211; Dependency-Driven Greenthreads</a><ul>
<li><a class="reference internal" href="#rationale">Rationale</a></li>
<li><a class="reference internal" href="#tutorial">Tutorial</a><ul>
<li><a class="reference internal" href="#example">Example</a></li>
<li><a class="reference internal" href="#introspection">Introspection</a></li>
<li><a class="reference internal" href="#posting">Posting</a></li>
<li><a class="reference internal" href="#preloading">Preloading</a></li>
<li><a class="reference internal" href="#exception-propagation">Exception Propagation</a></li>
<li><a class="reference internal" href="#scanning-for-success-exceptions">Scanning for Success / Exceptions</a></li>
</ul>
</li>
</ul>
</li>
<li><a class="reference internal" href="#module-eventlet.dagpool">Module Contents</a></li>
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="corolocal.html"
title="previous chapter"><code class="docutils literal"><span class="pre">corolocal</span></code> &#8211; Coroutine local storage</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="debug.html"
title="next chapter"><code class="docutils literal"><span class="pre">debug</span></code> &#8211; Debugging tools for Eventlet</a></p>
<div role="note" aria-label="source link">
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="../_sources/modules/dagpool.txt"
rel="nofollow">Show Source</a></li>
</ul>
</div>
<div id="searchbox" style="display: none" role="search">
<h3>Quick search</h3>
<form class="search" action="../search.html" method="get">
<input type="text" name="q" />
<input type="submit" value="Go" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
<p class="searchtip" style="font-size: 90%">
Enter search terms or a module, class or function name.
</p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="related" role="navigation" aria-label="related navigation">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../genindex.html" title="General Index"
>index</a></li>
<li class="right" >
<a href="../py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="right" >
<a href="debug.html" title="debug Debugging tools for Eventlet"
>next</a> |</li>
<li class="right" >
<a href="corolocal.html" title="corolocal Coroutine local storage"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>
<div class="footer" role="contentinfo">
&copy; Copyright 2005-2010, Eventlet Contributors.
Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.3.5.
</div>
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-42952223-1', 'eventlet.net');
ga('send', 'pageview');
</script>
</body>
</html>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>db_pool DBAPI 2 database connection pooling &mdash; Eventlet 0.19.0 documentation</title>
<title>db_pool DBAPI 2 database connection pooling &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="event Cross-greenthread primitive" href="event.html" />
<link rel="prev" title="debug Debugging tools for Eventlet" href="debug.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="debug.html" title="debug Debugging tools for Eventlet"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -439,7 +439,7 @@ connections.</p>
<li class="right" >
<a href="debug.html" title="debug Debugging tools for Eventlet"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>debug Debugging tools for Eventlet &mdash; Eventlet 0.19.0 documentation</title>
<title>debug Debugging tools for Eventlet &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,10 +23,10 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="db_pool DBAPI 2 database connection pooling" href="db_pool.html" />
<link rel="prev" title="corolocal Coroutine local storage" href="corolocal.html" />
<link rel="prev" title="dagpool Dependency-Driven Greenthreads" href="dagpool.html" />
</head>
<body role="document">
<div class="related" role="navigation" aria-label="related navigation">
@ -42,9 +42,9 @@
<a href="db_pool.html" title="db_pool DBAPI 2 database connection pooling"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="corolocal.html" title="corolocal Coroutine local storage"
<a href="dagpool.html" title="dagpool Dependency-Driven Greenthreads"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -157,8 +157,8 @@ positives.</p>
<div class="sphinxsidebar" role="navigation" aria-label="main navigation">
<div class="sphinxsidebarwrapper">
<h4>Previous topic</h4>
<p class="topless"><a href="corolocal.html"
title="previous chapter"><code class="docutils literal"><span class="pre">corolocal</span></code> &#8211; Coroutine local storage</a></p>
<p class="topless"><a href="dagpool.html"
title="previous chapter"><code class="docutils literal"><span class="pre">dagpool</span></code> &#8211; Dependency-Driven Greenthreads</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="db_pool.html"
title="next chapter"><code class="docutils literal"><span class="pre">db_pool</span></code> &#8211; DBAPI 2 database connection pooling</a></p>
@ -199,9 +199,9 @@ positives.</p>
<a href="db_pool.html" title="db_pool DBAPI 2 database connection pooling"
>next</a> |</li>
<li class="right" >
<a href="corolocal.html" title="corolocal Coroutine local storage"
<a href="dagpool.html" title="dagpool Dependency-Driven Greenthreads"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>event Cross-greenthread primitive &mdash; Eventlet 0.19.0 documentation</title>
<title>event Cross-greenthread primitive &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="greenpool Green Thread Pools" href="greenpool.html" />
<link rel="prev" title="db_pool DBAPI 2 database connection pooling" href="db_pool.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="db_pool.html" title="db_pool DBAPI 2 database connection pooling"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -245,7 +245,7 @@ occurred.</p>
<li class="right" >
<a href="db_pool.html" title="db_pool DBAPI 2 database connection pooling"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>greenpool Green Thread Pools &mdash; Eventlet 0.19.0 documentation</title>
<title>greenpool Green Thread Pools &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="greenthread Green Thread Implementation" href="greenthread.html" />
<link rel="prev" title="event Cross-greenthread primitive" href="event.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="event.html" title="event Cross-greenthread primitive"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -228,7 +228,7 @@ iterating over the GreenPile object.</p>
<li class="right" >
<a href="event.html" title="event Cross-greenthread primitive"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>greenthread Green Thread Implementation &mdash; Eventlet 0.19.0 documentation</title>
<title>greenthread Green Thread Implementation &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="pools - Generic pools of resources" href="pools.html" />
<link rel="prev" title="greenpool Green Thread Pools" href="greenpool.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="greenpool.html" title="greenpool Green Thread Pools"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -252,7 +252,7 @@ greenthread module).</p>
<li class="right" >
<a href="greenpool.html" title="greenpool Green Thread Pools"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>pools - Generic pools of resources &mdash; Eventlet 0.19.0 documentation</title>
<title>pools - Generic pools of resources &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="queue Queue class" href="queue.html" />
<link rel="prev" title="greenthread Green Thread Implementation" href="greenthread.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="greenthread.html" title="greenthread Green Thread Implementation"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -232,7 +232,7 @@ limited resource.</p>
<li class="right" >
<a href="greenthread.html" title="greenthread Green Thread Implementation"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>queue Queue class &mdash; Eventlet 0.19.0 documentation</title>
<title>queue Queue class &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="semaphore Semaphore classes" href="semaphore.html" />
<link rel="prev" title="pools - Generic pools of resources" href="pools.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="pools.html" title="pools - Generic pools of resources"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -274,7 +274,7 @@ items into the queue.</p>
<li class="right" >
<a href="pools.html" title="pools - Generic pools of resources"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>semaphore Semaphore classes &mdash; Eventlet 0.19.0 documentation</title>
<title>semaphore Semaphore classes &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="timeout Universal Timeouts" href="timeout.html" />
<link rel="prev" title="queue Queue class" href="queue.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="queue.html" title="queue Queue class"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -287,7 +287,7 @@ counter is greater than or equal to <em>limit</em>.</p>
<li class="right" >
<a href="queue.html" title="queue Queue class"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>timeout Universal Timeouts &mdash; Eventlet 0.19.0 documentation</title>
<title>timeout Universal Timeouts &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="websocket Websocket Server" href="websocket.html" />
<link rel="prev" title="semaphore Semaphore classes" href="semaphore.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="semaphore.html" title="semaphore Semaphore classes"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -225,7 +225,7 @@ is passed through to the caller.</p>
<li class="right" >
<a href="semaphore.html" title="semaphore Semaphore classes"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>websocket Websocket Server &mdash; Eventlet 0.19.0 documentation</title>
<title>websocket Websocket Server &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="wsgi WSGI server" href="wsgi.html" />
<link rel="prev" title="timeout Universal Timeouts" href="timeout.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="timeout.html" title="timeout Universal Timeouts"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -201,7 +201,7 @@ websocket message.</p>
<li class="right" >
<a href="timeout.html" title="timeout Universal Timeouts"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>wsgi WSGI server &mdash; Eventlet 0.19.0 documentation</title>
<title>wsgi WSGI server &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="eventlet.green.zmq ØMQ support" href="zmq.html" />
<link rel="prev" title="websocket Websocket Server" href="websocket.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="websocket.html" title="websocket Websocket Server"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -299,7 +299,7 @@ in the wsgi test case <code class="docutils literal"><span class="pre">tests/wsg
<li class="right" >
<a href="websocket.html" title="websocket Websocket Server"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>eventlet.green.zmq ØMQ support &mdash; Eventlet 0.19.0 documentation</title>
<title>eventlet.green.zmq ØMQ support &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="../index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="../index.html" />
<link rel="up" title="Module Reference" href="../modules.html" />
<link rel="next" title="Authors" href="../authors.html" />
<link rel="prev" title="wsgi WSGI server" href="wsgi.html" />
@ -44,7 +44,7 @@
<li class="right" >
<a href="wsgi.html" title="wsgi WSGI server"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" accesskey="U">Module Reference</a> &raquo;</li>
</ul>
</div>
@ -54,29 +54,781 @@
<div class="bodywrapper">
<div class="body" role="main">
<div class="section" id="eventlet-green-zmq-omq-support">
<h1><code class="xref py py-mod docutils literal"><span class="pre">eventlet.green.zmq</span></code> &#8211; ØMQ support<a class="headerlink" href="#eventlet-green-zmq-omq-support" title="Permalink to this headline"></a></h1>
<div class="section" id="module-eventlet.green.zmq">
<span id="eventlet-green-zmq-omq-support"></span><h1><a class="reference internal" href="#module-eventlet.green.zmq" title="eventlet.green.zmq"><code class="xref py py-mod docutils literal"><span class="pre">eventlet.green.zmq</span></code></a> &#8211; ØMQ support<a class="headerlink" href="#module-eventlet.green.zmq" title="Permalink to this headline"></a></h1>
<p>The <a class="reference internal" href="#module-zmq" title="zmq"><code class="xref py py-mod docutils literal"><span class="pre">zmq</span></code></a> module wraps the <a class="reference internal" href="#eventlet.green.zmq.Socket" title="eventlet.green.zmq.Socket"><code class="xref py py-class docutils literal"><span class="pre">Socket</span></code></a> and <a class="reference internal" href="#eventlet.green.zmq.Context" title="eventlet.green.zmq.Context"><code class="xref py py-class docutils literal"><span class="pre">Context</span></code></a>
found in <a class="reference internal" href="#module-zmq" title="zmq"><code class="xref py py-mod docutils literal"><span class="pre">pyzmq</span></code></a> to be non blocking</p>
<dl class="class">
<dt id="eventlet.green.zmq.Context">
<em class="property">class </em><code class="descclassname">eventlet.green.zmq.</code><code class="descname">Context</code><span class="sig-paren">(</span><em>io_threads=1</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Context" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">zmq.sugar.context.Context</span></code></p>
<p>Subclass of <a class="reference internal" href="#zmq.Context" title="zmq.Context"><code class="xref py py-class docutils literal"><span class="pre">zmq.Context</span></code></a></p>
<dl class="method">
<dt id="eventlet.green.zmq.Context.socket">
<code class="descname">socket</code><span class="sig-paren">(</span><em>socket_type</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Context.socket" title="Permalink to this definition"></a></dt>
<dd><p>Overridden method to ensure that the green version of socket is used</p>
<p>Behaves the same as <a class="reference internal" href="#zmq.Context.socket" title="zmq.Context.socket"><code class="xref py py-meth docutils literal"><span class="pre">zmq.Context.socket()</span></code></a>, but ensures
that a <a class="reference internal" href="#eventlet.green.zmq.Socket" title="eventlet.green.zmq.Socket"><code class="xref py py-class docutils literal"><span class="pre">Socket</span></code></a> with all of its send and recv methods set to be
non-blocking is returned</p>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="eventlet.green.zmq.Socket">
<em class="property">class </em><code class="descclassname">eventlet.green.zmq.</code><code class="descname">Socket</code><span class="sig-paren">(</span><em>context</em>, <em>socket_type</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal"><span class="pre">zmq.sugar.socket.Socket</span></code></p>
<p>Green version of :class:<a href="#id1"><span class="problematic" id="id2">`</span></a>zmq.core.socket.Socket</p>
<dl class="docutils">
<dt>The following three methods are always overridden:</dt>
<dd><ul class="first last simple">
<li>send</li>
<li>recv</li>
<li>getsockopt</li>
</ul>
</dd>
</dl>
<p>To ensure that the <code class="docutils literal"><span class="pre">zmq.NOBLOCK</span></code> flag is set and that sending or receiving
is deferred to the hub (using <a class="reference internal" href="../hubs.html#eventlet.hubs.trampoline" title="eventlet.hubs.trampoline"><code class="xref py py-func docutils literal"><span class="pre">eventlet.hubs.trampoline()</span></code></a>) if a
<code class="docutils literal"><span class="pre">zmq.EAGAIN</span></code> (retry) error is raised</p>
<dl class="docutils">
<dt>For some socket types, the following methods are also overridden:</dt>
<dd><ul class="first last simple">
<li>send_multipart</li>
<li>recv_multipart</li>
</ul>
</dd>
</dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.recv">
<code class="descname">recv</code><span class="sig-paren">(</span><em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.recv" title="Permalink to this definition"></a></dt>
<dd><p>Receive a message.</p>
<dl class="docutils">
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>Any supported flag: NOBLOCK. If NOBLOCK is set, this method
will raise a ZMQError with EAGAIN if a message is not ready.
If NOBLOCK is not set, then this method will block until a
message arrives.</dd>
<dt>copy <span class="classifier-delimiter">:</span> <span class="classifier">bool</span></dt>
<dd>Should the message be received in a copying or non-copying manner?
If False a Frame object is returned, if True a string copy of
message is returned.</dd>
<dt>track <span class="classifier-delimiter">:</span> <span class="classifier">bool</span></dt>
<dd>Should the message be tracked for notification that ZMQ has
finished with it? (ignored if copy=True)</dd>
</dl>
<dl class="docutils">
<dt>msg <span class="classifier-delimiter">:</span> <span class="classifier">bytes, Frame</span></dt>
<dd>The received message frame. If <cite>copy</cite> is False, then it will be a Frame,
otherwise it will be bytes.</dd>
</dl>
<dl class="docutils">
<dt>ZMQError</dt>
<dd>for any of the reasons zmq_msg_recv might fail.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.send">
<code class="descname">send</code><span class="sig-paren">(</span><em>data</em>, <em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.send" title="Permalink to this definition"></a></dt>
<dd><p>Send a message on this socket.</p>
<p>This queues the message to be sent by the IO thread at a later time.</p>
<dl class="docutils">
<dt>data <span class="classifier-delimiter">:</span> <span class="classifier">object, str, Frame</span></dt>
<dd>The content of the message.</dd>
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>Any supported flag: NOBLOCK, SNDMORE.</dd>
<dt>copy <span class="classifier-delimiter">:</span> <span class="classifier">bool</span></dt>
<dd>Should the message be sent in a copying or non-copying manner.</dd>
<dt>track <span class="classifier-delimiter">:</span> <span class="classifier">bool</span></dt>
<dd>Should the message be tracked for notification that ZMQ has
finished with it? (ignored if copy=True)</dd>
</dl>
<dl class="docutils">
<dt>None <span class="classifier-delimiter">:</span> <span class="classifier">if <cite>copy</cite> or not track</span></dt>
<dd>None if message was sent, raises an exception otherwise.</dd>
<dt>MessageTracker <span class="classifier-delimiter">:</span> <span class="classifier">if track and not copy</span></dt>
<dd>a MessageTracker object, whose <cite>pending</cite> property will
be True until the send is completed.</dd>
</dl>
<dl class="docutils">
<dt>TypeError</dt>
<dd>If a unicode object is passed</dd>
<dt>ValueError</dt>
<dd>If <cite>track=True</cite>, but an untracked Frame is passed.</dd>
<dt>ZMQError</dt>
<dd>If the send does not succeed for any reason.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.bind">
<code class="descname">bind</code><span class="sig-paren">(</span><em>addr</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.bind" title="Permalink to this definition"></a></dt>
<dd><p>Bind the socket to an address.</p>
<p>This causes the socket to listen on a network port. Sockets on the
other side of this connection will use <code class="docutils literal"><span class="pre">Socket.connect(addr)</span></code> to
connect to this socket.</p>
<dl class="docutils">
<dt>addr <span class="classifier-delimiter">:</span> <span class="classifier">str</span></dt>
<dd>The address string. This has the form &#8216;protocol://interface:port&#8217;,
for example &#8216;tcp://127.0.0.1:5555&#8217;. Protocols supported include
tcp, udp, pgm, epgm, inproc and ipc. If the address is unicode, it is
encoded to utf-8 first.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.bind_to_random_port">
<code class="descname">bind_to_random_port</code><span class="sig-paren">(</span><em>addr</em>, <em>min_port=49152</em>, <em>max_port=65536</em>, <em>max_tries=100</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.bind_to_random_port" title="Permalink to this definition"></a></dt>
<dd><p>bind this socket to a random port in a range</p>
<dl class="docutils">
<dt>addr <span class="classifier-delimiter">:</span> <span class="classifier">str</span></dt>
<dd>The address string without the port to pass to <code class="docutils literal"><span class="pre">Socket.bind()</span></code>.</dd>
<dt>min_port <span class="classifier-delimiter">:</span> <span class="classifier">int, optional</span></dt>
<dd>The minimum port in the range of ports to try (inclusive).</dd>
<dt>max_port <span class="classifier-delimiter">:</span> <span class="classifier">int, optional</span></dt>
<dd>The maximum port in the range of ports to try (exclusive).</dd>
<dt>max_tries <span class="classifier-delimiter">:</span> <span class="classifier">int, optional</span></dt>
<dd>The maximum number of bind attempts to make.</dd>
</dl>
<dl class="docutils">
<dt>port <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>The port the socket was bound to.</dd>
</dl>
<dl class="docutils">
<dt>ZMQBindError</dt>
<dd>if <cite>max_tries</cite> reached before successful bind</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.close">
<code class="descname">close</code><span class="sig-paren">(</span><em>linger=None</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.close" title="Permalink to this definition"></a></dt>
<dd><p>Close the socket.</p>
<p>If linger is specified, LINGER sockopt will be set prior to closing.</p>
<p>This can be called to close the socket by hand. If this is not
called, the socket will automatically be closed when it is
garbage collected.</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.connect">
<code class="descname">connect</code><span class="sig-paren">(</span><em>addr</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.connect" title="Permalink to this definition"></a></dt>
<dd><p>Connect to a remote 0MQ socket.</p>
<dl class="docutils">
<dt>addr <span class="classifier-delimiter">:</span> <span class="classifier">str</span></dt>
<dd>The address string. This has the form &#8216;protocol://interface:port&#8217;,
for example &#8216;tcp://127.0.0.1:5555&#8217;. Protocols supported are
tcp, upd, pgm, inproc and ipc. If the address is unicode, it is
encoded to utf-8 first.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.disconnect">
<code class="descname">disconnect</code><span class="sig-paren">(</span><em>addr</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.disconnect" title="Permalink to this definition"></a></dt>
<dd><p>Disconnect from a remote 0MQ socket (undoes a call to connect).</p>
<p>This feature requires libzmq-3</p>
<dl class="docutils">
<dt>addr <span class="classifier-delimiter">:</span> <span class="classifier">str</span></dt>
<dd>The address string. This has the form &#8216;protocol://interface:port&#8217;,
for example &#8216;tcp://127.0.0.1:5555&#8217;. Protocols supported are
tcp, upd, pgm, inproc and ipc. If the address is unicode, it is
encoded to utf-8 first.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.get">
<code class="descname">get</code><span class="sig-paren">(</span><em>option</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.get" title="Permalink to this definition"></a></dt>
<dd><p>Get the value of a socket option.</p>
<p>See the 0MQ API documentation for details on specific options.</p>
<dl class="docutils">
<dt>option <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd><p class="first">The option to get. Available values will depend on your
version of libzmq. Examples include:</p>
<div class="last highlight-python"><div class="highlight"><pre><span class="n">zmq</span><span class="o">.</span><span class="n">IDENTITY</span><span class="p">,</span> <span class="n">HWM</span><span class="p">,</span> <span class="n">LINGER</span><span class="p">,</span> <span class="n">FD</span><span class="p">,</span> <span class="n">EVENTS</span>
</pre></div>
</div>
</dd>
</dl>
<dl class="docutils">
<dt>optval <span class="classifier-delimiter">:</span> <span class="classifier">int or bytes</span></dt>
<dd>The value of the option as a bytestring or int.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.get_hwm">
<code class="descname">get_hwm</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.get_hwm" title="Permalink to this definition"></a></dt>
<dd><p>get the High Water Mark</p>
<p>On libzmq ≥ 3.x, this gets SNDHWM if available, otherwise RCVHWM</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.get_string">
<code class="descname">get_string</code><span class="sig-paren">(</span><em>option</em>, <em>encoding='utf-8'</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.get_string" title="Permalink to this definition"></a></dt>
<dd><p>get the value of a socket option</p>
<p>See the 0MQ documentation for details on specific options.</p>
<dl class="docutils">
<dt>option <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>The option to retrieve. Currently, IDENTITY is the only
gettable option that can return a string.</dd>
</dl>
<dl class="docutils">
<dt>optval <span class="classifier-delimiter">:</span> <span class="classifier">unicode string (unicode on py2, str on py3)</span></dt>
<dd>The value of the option as a unicode string.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.getsockopt">
<code class="descname">getsockopt</code><span class="sig-paren">(</span><em>option</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.getsockopt" title="Permalink to this definition"></a></dt>
<dd><p>s.get(option)</p>
<p>Get the value of a socket option.</p>
<p>See the 0MQ API documentation for details on specific options.</p>
<dl class="docutils">
<dt>option <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd><p class="first">The option to get. Available values will depend on your
version of libzmq. Examples include:</p>
<div class="last highlight-python"><div class="highlight"><pre><span class="n">zmq</span><span class="o">.</span><span class="n">IDENTITY</span><span class="p">,</span> <span class="n">HWM</span><span class="p">,</span> <span class="n">LINGER</span><span class="p">,</span> <span class="n">FD</span><span class="p">,</span> <span class="n">EVENTS</span>
</pre></div>
</div>
</dd>
</dl>
<dl class="docutils">
<dt>optval <span class="classifier-delimiter">:</span> <span class="classifier">int or bytes</span></dt>
<dd>The value of the option as a bytestring or int.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.getsockopt_string">
<code class="descname">getsockopt_string</code><span class="sig-paren">(</span><em>option</em>, <em>encoding='utf-8'</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.getsockopt_string" title="Permalink to this definition"></a></dt>
<dd><p>get the value of a socket option</p>
<p>See the 0MQ documentation for details on specific options.</p>
<dl class="docutils">
<dt>option <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>The option to retrieve. Currently, IDENTITY is the only
gettable option that can return a string.</dd>
</dl>
<dl class="docutils">
<dt>optval <span class="classifier-delimiter">:</span> <span class="classifier">unicode string (unicode on py2, str on py3)</span></dt>
<dd>The value of the option as a unicode string.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.getsockopt_unicode">
<code class="descname">getsockopt_unicode</code><span class="sig-paren">(</span><em>option</em>, <em>encoding='utf-8'</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.getsockopt_unicode" title="Permalink to this definition"></a></dt>
<dd><p>get the value of a socket option</p>
<p>See the 0MQ documentation for details on specific options.</p>
<dl class="docutils">
<dt>option <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>The option to retrieve. Currently, IDENTITY is the only
gettable option that can return a string.</dd>
</dl>
<dl class="docutils">
<dt>optval <span class="classifier-delimiter">:</span> <span class="classifier">unicode string (unicode on py2, str on py3)</span></dt>
<dd>The value of the option as a unicode string.</dd>
</dl>
</dd></dl>
<dl class="attribute">
<dt id="eventlet.green.zmq.Socket.hwm">
<code class="descname">hwm</code><a class="headerlink" href="#eventlet.green.zmq.Socket.hwm" title="Permalink to this definition"></a></dt>
<dd><p>get the High Water Mark</p>
<p>On libzmq ≥ 3.x, this gets SNDHWM if available, otherwise RCVHWM</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.poll">
<code class="descname">poll</code><span class="sig-paren">(</span><em>timeout=None</em>, <em>flags=1</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.poll" title="Permalink to this definition"></a></dt>
<dd><p>poll the socket for events</p>
<p>The default is to poll forever for incoming
events. Timeout is in milliseconds, if specified.</p>
<dl class="docutils">
<dt>timeout <span class="classifier-delimiter">:</span> <span class="classifier">int [default: None]</span></dt>
<dd>The timeout (in milliseconds) to wait for an event. If unspecified
(or secified None), will wait forever for an event.</dd>
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">bitfield (int) [default: POLLIN]</span></dt>
<dd>The event flags to poll for (any combination of POLLIN|POLLOUT).
The default is to check for incoming events (POLLIN).</dd>
</dl>
<dl class="docutils">
<dt>events <span class="classifier-delimiter">:</span> <span class="classifier">bitfield (int)</span></dt>
<dd>The events that are ready and waiting. Will be 0 if no events were ready
by the time timeout was reached.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt>
<code class="descname">recv</code><span class="sig-paren">(</span><em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span></dt>
<dd><p>Receive a message.</p>
<dl class="docutils">
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>Any supported flag: NOBLOCK. If NOBLOCK is set, this method
will raise a ZMQError with EAGAIN if a message is not ready.
If NOBLOCK is not set, then this method will block until a
message arrives.</dd>
<dt>copy <span class="classifier-delimiter">:</span> <span class="classifier">bool</span></dt>
<dd>Should the message be received in a copying or non-copying manner?
If False a Frame object is returned, if True a string copy of
message is returned.</dd>
<dt>track <span class="classifier-delimiter">:</span> <span class="classifier">bool</span></dt>
<dd>Should the message be tracked for notification that ZMQ has
finished with it? (ignored if copy=True)</dd>
</dl>
<dl class="docutils">
<dt>msg <span class="classifier-delimiter">:</span> <span class="classifier">bytes, Frame</span></dt>
<dd>The received message frame. If <cite>copy</cite> is False, then it will be a Frame,
otherwise it will be bytes.</dd>
</dl>
<dl class="docutils">
<dt>ZMQError</dt>
<dd>for any of the reasons zmq_msg_recv might fail.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.recv_json">
<code class="descname">recv_json</code><span class="sig-paren">(</span><em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.recv_json" title="Permalink to this definition"></a></dt>
<dd><p>receive a Python object as a message using json to serialize</p>
<dl class="docutils">
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>Any valid recv flag.</dd>
</dl>
<dl class="docutils">
<dt>obj <span class="classifier-delimiter">:</span> <span class="classifier">Python object</span></dt>
<dd>The Python object that arrives as a message.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.recv_multipart">
<code class="descname">recv_multipart</code><span class="sig-paren">(</span><em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.recv_multipart" title="Permalink to this definition"></a></dt>
<dd><p>receive a multipart message as a list of bytes or Frame objects</p>
<dl class="docutils">
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int, optional</span></dt>
<dd>Any supported flag: NOBLOCK. If NOBLOCK is set, this method
will raise a ZMQError with EAGAIN if a message is not ready.
If NOBLOCK is not set, then this method will block until a
message arrives.</dd>
<dt>copy <span class="classifier-delimiter">:</span> <span class="classifier">bool, optional</span></dt>
<dd>Should the message frame(s) be received in a copying or non-copying manner?
If False a Frame object is returned for each part, if True a copy of
the bytes is made for each frame.</dd>
<dt>track <span class="classifier-delimiter">:</span> <span class="classifier">bool, optional</span></dt>
<dd>Should the message frame(s) be tracked for notification that ZMQ has
finished with it? (ignored if copy=True)</dd>
</dl>
<dl class="docutils">
<dt>msg_parts <span class="classifier-delimiter">:</span> <span class="classifier">list</span></dt>
<dd>A list of frames in the multipart message; either Frames or bytes,
depending on <cite>copy</cite>.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.recv_pyobj">
<code class="descname">recv_pyobj</code><span class="sig-paren">(</span><em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.recv_pyobj" title="Permalink to this definition"></a></dt>
<dd><p>receive a Python object as a message using pickle to serialize</p>
<dl class="docutils">
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>Any valid recv flag.</dd>
</dl>
<dl class="docutils">
<dt>obj <span class="classifier-delimiter">:</span> <span class="classifier">Python object</span></dt>
<dd>The Python object that arrives as a message.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.recv_string">
<code class="descname">recv_string</code><span class="sig-paren">(</span><em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.recv_string" title="Permalink to this definition"></a></dt>
<dd><p>receive a unicode string, as sent by send_string</p>
<dl class="docutils">
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>Any valid recv flag.</dd>
<dt>encoding <span class="classifier-delimiter">:</span> <span class="classifier">str [default: &#8216;utf-8&#8217;]</span></dt>
<dd>The encoding to be used</dd>
</dl>
<dl class="docutils">
<dt>s <span class="classifier-delimiter">:</span> <span class="classifier">unicode string (unicode on py2, str on py3)</span></dt>
<dd>The Python unicode string that arrives as encoded bytes.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.recv_unicode">
<code class="descname">recv_unicode</code><span class="sig-paren">(</span><em>flags=0</em>, <em>encoding='utf-8'</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.recv_unicode" title="Permalink to this definition"></a></dt>
<dd><p>receive a unicode string, as sent by send_string</p>
<dl class="docutils">
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>Any valid recv flag.</dd>
<dt>encoding <span class="classifier-delimiter">:</span> <span class="classifier">str [default: &#8216;utf-8&#8217;]</span></dt>
<dd>The encoding to be used</dd>
</dl>
<dl class="docutils">
<dt>s <span class="classifier-delimiter">:</span> <span class="classifier">unicode string (unicode on py2, str on py3)</span></dt>
<dd>The Python unicode string that arrives as encoded bytes.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt>
<code class="descname">send</code><span class="sig-paren">(</span><em>data</em>, <em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span></dt>
<dd><p>Send a message on this socket.</p>
<p>This queues the message to be sent by the IO thread at a later time.</p>
<dl class="docutils">
<dt>data <span class="classifier-delimiter">:</span> <span class="classifier">object, str, Frame</span></dt>
<dd>The content of the message.</dd>
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>Any supported flag: NOBLOCK, SNDMORE.</dd>
<dt>copy <span class="classifier-delimiter">:</span> <span class="classifier">bool</span></dt>
<dd>Should the message be sent in a copying or non-copying manner.</dd>
<dt>track <span class="classifier-delimiter">:</span> <span class="classifier">bool</span></dt>
<dd>Should the message be tracked for notification that ZMQ has
finished with it? (ignored if copy=True)</dd>
</dl>
<dl class="docutils">
<dt>None <span class="classifier-delimiter">:</span> <span class="classifier">if <cite>copy</cite> or not track</span></dt>
<dd>None if message was sent, raises an exception otherwise.</dd>
<dt>MessageTracker <span class="classifier-delimiter">:</span> <span class="classifier">if track and not copy</span></dt>
<dd>a MessageTracker object, whose <cite>pending</cite> property will
be True until the send is completed.</dd>
</dl>
<dl class="docutils">
<dt>TypeError</dt>
<dd>If a unicode object is passed</dd>
<dt>ValueError</dt>
<dd>If <cite>track=True</cite>, but an untracked Frame is passed.</dd>
<dt>ZMQError</dt>
<dd>If the send does not succeed for any reason.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.send_json">
<code class="descname">send_json</code><span class="sig-paren">(</span><em>msg_parts</em>, <em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.send_json" title="Permalink to this definition"></a></dt>
<dd><p>send a Python object as a message using json to serialize</p>
<dl class="docutils">
<dt>obj <span class="classifier-delimiter">:</span> <span class="classifier">Python object</span></dt>
<dd>The Python object to send.</dd>
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>Any valid send flag.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.send_multipart">
<code class="descname">send_multipart</code><span class="sig-paren">(</span><em>msg_parts</em>, <em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.send_multipart" title="Permalink to this definition"></a></dt>
<dd><p>send a sequence of buffers as a multipart message</p>
<dl class="docutils">
<dt>msg_parts <span class="classifier-delimiter">:</span> <span class="classifier">iterable</span></dt>
<dd>A sequence of objects to send as a multipart message. Each element
can be any sendable object (Frame, bytes, buffer-providers)</dd>
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int, optional</span></dt>
<dd>SNDMORE is handled automatically for frames before the last.</dd>
<dt>copy <span class="classifier-delimiter">:</span> <span class="classifier">bool, optional</span></dt>
<dd>Should the frame(s) be sent in a copying or non-copying manner.</dd>
<dt>track <span class="classifier-delimiter">:</span> <span class="classifier">bool, optional</span></dt>
<dd>Should the frame(s) be tracked for notification that ZMQ has
finished with it (ignored if copy=True).</dd>
</dl>
<p>None : if copy or not track
MessageTracker : if track and not copy</p>
<blockquote>
<div>a MessageTracker object, whose <cite>pending</cite> property will
be True until the last send is completed.</div></blockquote>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.send_pyobj">
<code class="descname">send_pyobj</code><span class="sig-paren">(</span><em>msg_parts</em>, <em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.send_pyobj" title="Permalink to this definition"></a></dt>
<dd><p>send a Python object as a message using pickle to serialize</p>
<dl class="docutils">
<dt>obj <span class="classifier-delimiter">:</span> <span class="classifier">Python object</span></dt>
<dd>The Python object to send.</dd>
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>Any valid send flag.</dd>
<dt>protocol <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>The pickle protocol number to use. Default of -1 will select
the highest supported number. Use 0 for multiple platform
support.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.send_string">
<code class="descname">send_string</code><span class="sig-paren">(</span><em>msg_parts</em>, <em>flags=0</em>, <em>copy=True</em>, <em>track=False</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.send_string" title="Permalink to this definition"></a></dt>
<dd><p>send a Python unicode string as a message with an encoding</p>
<p>0MQ communicates with raw bytes, so you must encode/decode
text (unicode on py2, str on py3) around 0MQ.</p>
<dl class="docutils">
<dt>u <span class="classifier-delimiter">:</span> <span class="classifier">Python unicode string (unicode on py2, str on py3)</span></dt>
<dd>The unicode string to send.</dd>
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int, optional</span></dt>
<dd>Any valid send flag.</dd>
<dt>encoding <span class="classifier-delimiter">:</span> <span class="classifier">str [default: &#8216;utf-8&#8217;]</span></dt>
<dd>The encoding to be used</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.send_unicode">
<code class="descname">send_unicode</code><span class="sig-paren">(</span><em>u</em>, <em>flags=0</em>, <em>copy=False</em>, <em>encoding='utf-8'</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.send_unicode" title="Permalink to this definition"></a></dt>
<dd><p>send a Python unicode string as a message with an encoding</p>
<p>0MQ communicates with raw bytes, so you must encode/decode
text (unicode on py2, str on py3) around 0MQ.</p>
<dl class="docutils">
<dt>u <span class="classifier-delimiter">:</span> <span class="classifier">Python unicode string (unicode on py2, str on py3)</span></dt>
<dd>The unicode string to send.</dd>
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int, optional</span></dt>
<dd>Any valid send flag.</dd>
<dt>encoding <span class="classifier-delimiter">:</span> <span class="classifier">str [default: &#8216;utf-8&#8217;]</span></dt>
<dd>The encoding to be used</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.set">
<code class="descname">set</code><span class="sig-paren">(</span><em>option</em>, <em>optval</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.set" title="Permalink to this definition"></a></dt>
<dd><p>Set socket options.</p>
<p>See the 0MQ API documentation for details on specific options.</p>
<dl class="docutils">
<dt>option <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd><p class="first">The option to set. Available values will depend on your
version of libzmq. Examples include:</p>
<div class="last highlight-python"><div class="highlight"><pre><span class="n">zmq</span><span class="o">.</span><span class="n">SUBSCRIBE</span><span class="p">,</span> <span class="n">UNSUBSCRIBE</span><span class="p">,</span> <span class="n">IDENTITY</span><span class="p">,</span> <span class="n">HWM</span><span class="p">,</span> <span class="n">LINGER</span><span class="p">,</span> <span class="n">FD</span>
</pre></div>
</div>
</dd>
<dt>optval <span class="classifier-delimiter">:</span> <span class="classifier">int or bytes</span></dt>
<dd>The value of the option to set.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.set_hwm">
<code class="descname">set_hwm</code><span class="sig-paren">(</span><em>value</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.set_hwm" title="Permalink to this definition"></a></dt>
<dd><p>set the High Water Mark</p>
<p>On libzmq ≥ 3.x, this sets <em>both</em> SNDHWM and RCVHWM</p>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.set_string">
<code class="descname">set_string</code><span class="sig-paren">(</span><em>option</em>, <em>optval</em>, <em>encoding='utf-8'</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.set_string" title="Permalink to this definition"></a></dt>
<dd><p>set socket options with a unicode object</p>
<p>This is simply a wrapper for setsockopt to protect from encoding ambiguity.</p>
<p>See the 0MQ documentation for details on specific options.</p>
<dl class="docutils">
<dt>option <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>The name of the option to set. Can be any of: SUBSCRIBE,
UNSUBSCRIBE, IDENTITY</dd>
<dt>optval <span class="classifier-delimiter">:</span> <span class="classifier">unicode string (unicode on py2, str on py3)</span></dt>
<dd>The value of the option to set.</dd>
<dt>encoding <span class="classifier-delimiter">:</span> <span class="classifier">str</span></dt>
<dd>The encoding to be used, default is utf8</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.setsockopt">
<code class="descname">setsockopt</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.setsockopt" title="Permalink to this definition"></a></dt>
<dd><p>s.set(option, optval)</p>
<p>Set socket options.</p>
<p>See the 0MQ API documentation for details on specific options.</p>
<dl class="docutils">
<dt>option <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd><p class="first">The option to set. Available values will depend on your
version of libzmq. Examples include:</p>
<div class="last highlight-python"><div class="highlight"><pre><span class="n">zmq</span><span class="o">.</span><span class="n">SUBSCRIBE</span><span class="p">,</span> <span class="n">UNSUBSCRIBE</span><span class="p">,</span> <span class="n">IDENTITY</span><span class="p">,</span> <span class="n">HWM</span><span class="p">,</span> <span class="n">LINGER</span><span class="p">,</span> <span class="n">FD</span>
</pre></div>
</div>
</dd>
<dt>optval <span class="classifier-delimiter">:</span> <span class="classifier">int or bytes</span></dt>
<dd>The value of the option to set.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.setsockopt_string">
<code class="descname">setsockopt_string</code><span class="sig-paren">(</span><em>option</em>, <em>optval</em>, <em>encoding='utf-8'</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.setsockopt_string" title="Permalink to this definition"></a></dt>
<dd><p>set socket options with a unicode object</p>
<p>This is simply a wrapper for setsockopt to protect from encoding ambiguity.</p>
<p>See the 0MQ documentation for details on specific options.</p>
<dl class="docutils">
<dt>option <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>The name of the option to set. Can be any of: SUBSCRIBE,
UNSUBSCRIBE, IDENTITY</dd>
<dt>optval <span class="classifier-delimiter">:</span> <span class="classifier">unicode string (unicode on py2, str on py3)</span></dt>
<dd>The value of the option to set.</dd>
<dt>encoding <span class="classifier-delimiter">:</span> <span class="classifier">str</span></dt>
<dd>The encoding to be used, default is utf8</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.setsockopt_unicode">
<code class="descname">setsockopt_unicode</code><span class="sig-paren">(</span><em>option</em>, <em>optval</em>, <em>encoding='utf-8'</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.setsockopt_unicode" title="Permalink to this definition"></a></dt>
<dd><p>set socket options with a unicode object</p>
<p>This is simply a wrapper for setsockopt to protect from encoding ambiguity.</p>
<p>See the 0MQ documentation for details on specific options.</p>
<dl class="docutils">
<dt>option <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>The name of the option to set. Can be any of: SUBSCRIBE,
UNSUBSCRIBE, IDENTITY</dd>
<dt>optval <span class="classifier-delimiter">:</span> <span class="classifier">unicode string (unicode on py2, str on py3)</span></dt>
<dd>The value of the option to set.</dd>
<dt>encoding <span class="classifier-delimiter">:</span> <span class="classifier">str</span></dt>
<dd>The encoding to be used, default is utf8</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="eventlet.green.zmq.Socket.unbind">
<code class="descname">unbind</code><span class="sig-paren">(</span><em>addr</em><span class="sig-paren">)</span><a class="headerlink" href="#eventlet.green.zmq.Socket.unbind" title="Permalink to this definition"></a></dt>
<dd><p>Unbind from an address (undoes a call to bind).</p>
<p>This feature requires libzmq-3</p>
<dl class="docutils">
<dt>addr <span class="classifier-delimiter">:</span> <span class="classifier">str</span></dt>
<dd>The address string. This has the form &#8216;protocol://interface:port&#8217;,
for example &#8216;tcp://127.0.0.1:5555&#8217;. Protocols supported are
tcp, upd, pgm, inproc and ipc. If the address is unicode, it is
encoded to utf-8 first.</dd>
</dl>
</dd></dl>
</dd></dl>
<span class="target" id="module-zmq"></span></div>
<div class="section" id="zmq-the-pyzmq-omq-python-bindings">
<h1><a class="reference internal" href="#module-zmq" title="zmq"><code class="xref py py-mod docutils literal"><span class="pre">zmq</span></code></a> &#8211; The pyzmq ØMQ python bindings<a class="headerlink" href="#zmq-the-pyzmq-omq-python-bindings" title="Permalink to this headline"></a></h1>
<p><a class="reference internal" href="#module-zmq" title="zmq"><code class="xref py py-mod docutils literal"><span class="pre">pyzmq</span></code></a> <a class="footnote-reference" href="#id4" id="id1">[1]</a> Is a python binding to the C++ ØMQ <a class="footnote-reference" href="#id5" id="id2">[2]</a> library written in Cython <a class="footnote-reference" href="#id6" id="id3">[3]</a>. The following is
<p><a class="reference internal" href="#module-zmq" title="zmq"><code class="xref py py-mod docutils literal"><span class="pre">pyzmq</span></code></a> <a class="footnote-reference" href="#id6" id="id3">[1]</a> Is a python binding to the C++ ØMQ <a class="footnote-reference" href="#id7" id="id4">[2]</a> library written in Cython <a class="footnote-reference" href="#id8" id="id5">[3]</a>. The following is
auto generated <a class="reference internal" href="#module-zmq" title="zmq"><code class="xref py py-mod docutils literal"><span class="pre">pyzmq's</span></code></a> from documentation.</p>
<table class="docutils footnote" frame="void" id="id4" rules="none">
<colgroup><col class="label" /><col /></colgroup>
<tbody valign="top">
<tr><td class="label"><a class="fn-backref" href="#id1">[1]</a></td><td><a class="reference external" href="http://github.com/zeromq/pyzmq">http://github.com/zeromq/pyzmq</a></td></tr>
</tbody>
</table>
<table class="docutils footnote" frame="void" id="id5" rules="none">
<colgroup><col class="label" /><col /></colgroup>
<tbody valign="top">
<tr><td class="label"><a class="fn-backref" href="#id2">[2]</a></td><td><a class="reference external" href="http://www.zeromq.com">http://www.zeromq.com</a></td></tr>
</tbody>
</table>
<dl class="class">
<dt id="zmq.Context">
<em class="property">class </em><code class="descclassname">zmq.</code><code class="descname">Context</code><span class="sig-paren">(</span><em>io_threads=1</em><span class="sig-paren">)</span><a class="headerlink" href="#zmq.Context" title="Permalink to this definition"></a></dt>
<dd><dl class="method">
<dt id="zmq.Context.getsockopt">
<code class="descname">getsockopt</code><span class="sig-paren">(</span><em>opt</em><span class="sig-paren">)</span><a class="headerlink" href="#zmq.Context.getsockopt" title="Permalink to this definition"></a></dt>
<dd><p>get default socket options for new sockets created by this Context</p>
</dd></dl>
<dl class="classmethod">
<dt id="zmq.Context.instance">
<em class="property">classmethod </em><code class="descname">instance</code><span class="sig-paren">(</span><em>io_threads=1</em><span class="sig-paren">)</span><a class="headerlink" href="#zmq.Context.instance" title="Permalink to this definition"></a></dt>
<dd><p>Returns a global Context instance.</p>
<p>Most single-threaded applications have a single, global Context.
Use this method instead of passing around Context instances
throughout your code.</p>
<p>A common pattern for classes that depend on Contexts is to use
a default argument to enable programs with multiple Contexts
but not require the argument for simpler applications:</p>
<blockquote>
<div><dl class="docutils">
<dt>class MyClass(object):</dt>
<dd><dl class="first last docutils">
<dt>def __init__(self, context=None):</dt>
<dd>self.context = context or Context.instance()</dd>
</dl>
</dd>
</dl>
</div></blockquote>
</dd></dl>
<dl class="method">
<dt id="zmq.Context.setsockopt">
<code class="descname">setsockopt</code><span class="sig-paren">(</span><em>opt</em>, <em>value</em><span class="sig-paren">)</span><a class="headerlink" href="#zmq.Context.setsockopt" title="Permalink to this definition"></a></dt>
<dd><p>set default socket options for new sockets created by this Context</p>
</dd></dl>
<dl class="method">
<dt id="zmq.Context.socket">
<code class="descname">socket</code><span class="sig-paren">(</span><em>socket_type</em><span class="sig-paren">)</span><a class="headerlink" href="#zmq.Context.socket" title="Permalink to this definition"></a></dt>
<dd><p>Create a Socket associated with this Context.</p>
<dl class="docutils">
<dt>socket_type <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>The socket type, which can be any of the 0MQ socket types:
REQ, REP, PUB, SUB, PAIR, DEALER, ROUTER, PULL, PUSH, XSUB, XPUB.</dd>
</dl>
</dd></dl>
</dd></dl>
<dl class="class">
<dt id="zmq.Socket">
<em class="property">class </em><code class="descclassname">zmq.</code><code class="descname">Socket</code><a class="headerlink" href="#zmq.Socket" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="class">
<dt id="zmq.Poller">
<em class="property">class </em><code class="descclassname">zmq.</code><code class="descname">Poller</code><a class="headerlink" href="#zmq.Poller" title="Permalink to this definition"></a></dt>
<dd><p>A stateful poll interface that mirrors Python&#8217;s built-in poll.</p>
<dl class="method">
<dt id="zmq.Poller.modify">
<code class="descname">modify</code><span class="sig-paren">(</span><em>socket</em>, <em>flags=POLLIN|POLLOUT</em><span class="sig-paren">)</span><a class="headerlink" href="#zmq.Poller.modify" title="Permalink to this definition"></a></dt>
<dd><p>Modify the flags for an already registered 0MQ socket or native fd.</p>
</dd></dl>
<dl class="method">
<dt id="zmq.Poller.poll">
<code class="descname">poll</code><span class="sig-paren">(</span><em>timeout=None</em><span class="sig-paren">)</span><a class="headerlink" href="#zmq.Poller.poll" title="Permalink to this definition"></a></dt>
<dd><p>Poll the registered 0MQ or native fds for I/O.</p>
<dl class="docutils">
<dt>timeout <span class="classifier-delimiter">:</span> <span class="classifier">float, int</span></dt>
<dd>The timeout in milliseconds. If None, no <cite>timeout</cite> (infinite). This
is in milliseconds to be compatible with <code class="docutils literal"><span class="pre">select.poll()</span></code>. The
underlying zmq_poll uses microseconds and we convert to that in
this function.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="zmq.Poller.register">
<code class="descname">register</code><span class="sig-paren">(</span><em>socket</em>, <em>flags=POLLIN|POLLOUT</em><span class="sig-paren">)</span><a class="headerlink" href="#zmq.Poller.register" title="Permalink to this definition"></a></dt>
<dd><p>Register a 0MQ socket or native fd for I/O monitoring.</p>
<p>register(s,0) is equivalent to unregister(s).</p>
<dl class="docutils">
<dt>socket <span class="classifier-delimiter">:</span> <span class="classifier">zmq.Socket or native socket</span></dt>
<dd>A zmq.Socket or any Python object having a <code class="docutils literal"><span class="pre">fileno()</span></code>
method that returns a valid file descriptor.</dd>
<dt>flags <span class="classifier-delimiter">:</span> <span class="classifier">int</span></dt>
<dd>The events to watch for. Can be POLLIN, POLLOUT or POLLIN|POLLOUT.
If <cite>flags=0</cite>, socket will be unregistered.</dd>
</dl>
</dd></dl>
<dl class="method">
<dt id="zmq.Poller.unregister">
<code class="descname">unregister</code><span class="sig-paren">(</span><em>socket</em><span class="sig-paren">)</span><a class="headerlink" href="#zmq.Poller.unregister" title="Permalink to this definition"></a></dt>
<dd><p>Remove a 0MQ socket or native fd for I/O monitoring.</p>
<dl class="docutils">
<dt>socket <span class="classifier-delimiter">:</span> <span class="classifier">Socket</span></dt>
<dd>The socket instance to stop polling.</dd>
</dl>
</dd></dl>
</dd></dl>
<table class="docutils footnote" frame="void" id="id6" rules="none">
<colgroup><col class="label" /><col /></colgroup>
<tbody valign="top">
<tr><td class="label"><a class="fn-backref" href="#id3">[3]</a></td><td><a class="reference external" href="http://www.cython.org">http://www.cython.org</a></td></tr>
<tr><td class="label"><a class="fn-backref" href="#id3">[1]</a></td><td><a class="reference external" href="http://github.com/zeromq/pyzmq">http://github.com/zeromq/pyzmq</a></td></tr>
</tbody>
</table>
<table class="docutils footnote" frame="void" id="id7" rules="none">
<colgroup><col class="label" /><col /></colgroup>
<tbody valign="top">
<tr><td class="label"><a class="fn-backref" href="#id4">[2]</a></td><td><a class="reference external" href="http://www.zeromq.com">http://www.zeromq.com</a></td></tr>
</tbody>
</table>
<table class="docutils footnote" frame="void" id="id8" rules="none">
<colgroup><col class="label" /><col /></colgroup>
<tbody valign="top">
<tr><td class="label"><a class="fn-backref" href="#id5">[3]</a></td><td><a class="reference external" href="http://www.cython.org">http://www.cython.org</a></td></tr>
</tbody>
</table>
</div>
@ -138,7 +890,7 @@ auto generated <a class="reference internal" href="#module-zmq" title="zmq"><cod
<li class="right" >
<a href="wsgi.html" title="wsgi WSGI server"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="../index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-1"><a href="../modules.html" >Module Reference</a> &raquo;</li>
</ul>
</div>

Binary file not shown.

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Greening The World &mdash; Eventlet 0.19.0 documentation</title>
<title>Greening The World &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="Examples" href="examples.html" />
<link rel="prev" title="Design Patterns" href="design_patterns.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="design_patterns.html" title="Design Patterns"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -180,7 +180,7 @@ library. This has the disadvantage of appearing quite magical, but the advantag
<li class="right" >
<a href="design_patterns.html" title="Design Patterns"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Python Module Index &mdash; Eventlet 0.19.0 documentation</title>
<title>Python Module Index &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
@ -38,7 +38,7 @@
<li class="right" >
<a href="#" title="Python Module Index"
>modules</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -75,6 +75,11 @@
<td>&nbsp;&nbsp;&nbsp;
<a href="modules/corolocal.html#module-eventlet.corolocal"><code class="xref">eventlet.corolocal</code></a></td><td>
<em></em></td></tr>
<tr class="cg-1">
<td></td>
<td>&nbsp;&nbsp;&nbsp;
<a href="modules/dagpool.html#module-eventlet.dagpool"><code class="xref">eventlet.dagpool</code></a></td><td>
<em></em></td></tr>
<tr class="cg-1">
<td></td>
<td>&nbsp;&nbsp;&nbsp;
@ -90,6 +95,11 @@
<td>&nbsp;&nbsp;&nbsp;
<a href="modules/event.html#module-eventlet.event"><code class="xref">eventlet.event</code></a></td><td>
<em></em></td></tr>
<tr class="cg-1">
<td></td>
<td>&nbsp;&nbsp;&nbsp;
<a href="modules/zmq.html#module-eventlet.green.zmq"><code class="xref">eventlet.green.zmq</code></a></td><td>
<em></em></td></tr>
<tr class="cg-1">
<td></td>
<td>&nbsp;&nbsp;&nbsp;
@ -167,7 +177,7 @@
<li class="right" >
<a href="#" title="Python Module Index"
>modules</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Search &mdash; Eventlet 0.19.0 documentation</title>
<title>Search &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -24,7 +24,7 @@
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="_static/searchtools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<script type="text/javascript">
jQuery(function() { Search.loadIndex("searchindex.js"); });
</script>
@ -43,7 +43,7 @@
<li class="right" >
<a href="py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -94,7 +94,7 @@
<li class="right" >
<a href="py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

File diff suppressed because one or more lines are too long

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Using SSL With Eventlet &mdash; Eventlet 0.19.0 documentation</title>
<title>Using SSL With Eventlet &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="Threads" href="threading.html" />
<link rel="prev" title="Examples" href="examples.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="examples.html" title="Examples"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -165,7 +165,7 @@ connection.close()
<li class="right" >
<a href="examples.html" title="Examples"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Testing Eventlet &mdash; Eventlet 0.19.0 documentation</title>
<title>Testing Eventlet &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="Environment Variables" href="environment.html" />
<link rel="prev" title="Understanding Eventlet Hubs" href="hubs.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="hubs.html" title="Understanding Eventlet Hubs"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -182,7 +182,7 @@
<li class="right" >
<a href="hubs.html" title="Understanding Eventlet Hubs"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Threads &mdash; Eventlet 0.19.0 documentation</title>
<title>Threads &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="Zeromq" href="zeromq.html" />
<link rel="prev" title="Using SSL With Eventlet" href="ssl.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="ssl.html" title="Using SSL With Eventlet"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -168,7 +168,7 @@ wrapped in Proxy objects when accessed.</p>
<li class="right" >
<a href="ssl.html" title="Using SSL With Eventlet"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -6,7 +6,7 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Zeromq &mdash; Eventlet 0.19.0 documentation</title>
<title>Zeromq &mdash; Eventlet 0.20.0 documentation</title>
<link rel="stylesheet" href="_static/classic.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
@ -14,7 +14,7 @@
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: './',
VERSION: '0.19.0',
VERSION: '0.20.0',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true
@ -23,7 +23,7 @@
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<link rel="top" title="Eventlet 0.19.0 documentation" href="index.html" />
<link rel="top" title="Eventlet 0.20.0 documentation" href="index.html" />
<link rel="next" title="Understanding Eventlet Hubs" href="hubs.html" />
<link rel="prev" title="Threads" href="threading.html" />
</head>
@ -43,7 +43,7 @@
<li class="right" >
<a href="threading.html" title="Threads"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>
@ -74,7 +74,7 @@ while simultaneously accepting incoming connections from multiple endpoints boun
</div>
<div class="section" id="api-documentation">
<h2>API documentation<a class="headerlink" href="#api-documentation" title="Permalink to this headline"></a></h2>
<p>ØMQ support is provided in the <code class="xref py py-mod docutils literal"><span class="pre">eventlet.green.zmq</span></code> module</p>
<p>ØMQ support is provided in the <a class="reference internal" href="modules/zmq.html#module-eventlet.green.zmq" title="eventlet.green.zmq"><code class="xref py py-mod docutils literal"><span class="pre">eventlet.green.zmq</span></code></a> module</p>
</div>
</div>
@ -138,7 +138,7 @@ while simultaneously accepting incoming connections from multiple endpoints boun
<li class="right" >
<a href="threading.html" title="Threads"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.19.0 documentation</a> &raquo;</li>
<li class="nav-item nav-item-0"><a href="index.html">Eventlet 0.20.0 documentation</a> &raquo;</li>
</ul>
</div>

View File

@ -54,7 +54,7 @@ pip install eventlet
<p>Alternately, you can download the source archive:</p>
<ul>
<li>latest release from <a class="reference external" target="_blank" href="https://pypi.python.org/pypi/eventlet/">PyPi</a>:
<a class="reference external" href="https://pypi.python.org/packages/source/e/eventlet/eventlet-0.19.0.tar.gz">eventlet-0.19.0.tar.gz</a></li>
<a class="reference external" href="https://pypi.python.org/packages/source/e/eventlet/eventlet-0.20.0.tar.gz">eventlet-0.20.0.tar.gz</a></li>
<li>or <a class="reference external" href="https://github.com/eventlet/eventlet/archive/master.zip">latest development version</a></li>
</ul>