Tornado 5.1 Documentation
support some shorthand for waiting on multiple objects by yielding a list or dict. Use tornado.gen.multi to do this in native coroutines. • Decorated coroutines can support integration with other packages blocking_func, args) Parallelism The multi function accepts lists and dicts whose values are Futures, and waits for all of those Futures in parallel: from tornado.gen import multi async def parallel_fetch(url1 parallel_fetch(url1, url2): resp1, resp2 = await multi([http_client.fetch(url1), http_client.fetch(url2)]) async def parallel_fetch_many(urls): responses = await multi ([http_client.fetch(url) for url in urls]) # responses0 码力 | 243 页 | 895.80 KB | 1 年前3
Tornado 5.1 Documentation
support some shorthand for waiting on multiple objects by yielding a list or dict. Use tornado.gen.multi to do this in native coroutines. Decorated coroutines can support integration with other packages blocking_func, args) Parallelism The multi function accepts lists and dicts whose values are Futures, and waits for all of those Futures in parallel: from tornado.gen import multi async def parallel_fetch(url1 resp1, resp2 = await multi([http_client.fetch(url1), http_client.fetch(url2)]) async def parallel_fetch_many(urls): responses = await multi ([http_client.fetch(url)0 码力 | 359 页 | 347.32 KB | 1 年前3
Tornado 6.1 Documentation
officially supported or recommended for pro- duction use. Some features are missing on Windows (including multi-process mode) and scalability is limited (Even though Tornado is built on asyncio, which supports support some shorthand for waiting on multiple objects by yielding a list or dict. Use tornado.gen. multi to do this in native coroutines. – can support integration with other packages including Twisted blocking_func, args) Parallelism The multi function accepts lists and dicts whose values are Futures, and waits for all of those Futures in parallel: from tornado.gen import multi async def parallel_fetch(url10 码力 | 245 页 | 904.24 KB | 1 年前3
Tornado 6.5 Documentationofficially supported or recommended for pro- duction use. Some features are missing on Windows (including multi-process mode) and scalability is limited (Even though Tornado is built on asyncio, which supports support some shorthand for waiting on multiple objects by yielding a list or dict. Use tornado.gen.multi to do this in native coroutines. – can support integration with other packages including Twisted blocking_func, args) Parallelism The multi function accepts lists and dicts whose values are Futures, and waits for all of those Futures in parallel: from tornado.gen import multi async def parallel_fetch(url10 码力 | 272 页 | 1.12 MB | 3 月前3
Tornado 6.2 Documentation
officially supported or recommended for pro- duction use. Some features are missing on Windows (including multi-process mode) and scalability is limited (Even though Tornado is built on asyncio, which supports support some shorthand for waiting on multiple objects by yielding a list or dict. Use tornado.gen.multi to do this in native coroutines. – can support integration with other packages including Twisted blocking_func, args) Parallelism The multi function accepts lists and dicts whose values are Futures, and waits for all of those Futures in parallel: from tornado.gen import multi async def parallel_fetch(url10 码力 | 260 页 | 1.06 MB | 1 年前3
Tornado 6.0 Documentation
support some shorthand for waiting on multiple objects by yielding a list or dict. Use tornado.gen. multi to do this in native coroutines. – can support integration with other packages including Twisted blocking_func, args) Parallelism The multi function accepts lists and dicts whose values are Futures, and waits for all of those Futures in parallel: from tornado.gen import multi async def parallel_fetch(url1 parallel_fetch(url1, url2): resp1, resp2 = await multi([http_client.fetch(url1), http_client.fetch(url2)]) async def parallel_fetch_many(urls): responses = await multi ([http_client.fetch(url) for url in urls]) # responses0 码力 | 245 页 | 885.76 KB | 1 年前3
Tornado 6.4 Documentation
officially supported or recommended for pro- duction use. Some features are missing on Windows (including multi-process mode) and scalability is limited (Even though Tornado is built on asyncio, which supports support some shorthand for waiting on multiple objects by yielding a list or dict. Use tornado.gen.multi to do this in native coroutines. – can support integration with other packages including Twisted blocking_func, args) Parallelism The multi function accepts lists and dicts whose values are Futures, and waits for all of those Futures in parallel: from tornado.gen import multi async def parallel_fetch(url10 码力 | 268 页 | 1.09 MB | 1 年前3
Tornado 6.4 Documentation
officially supported or recommended for pro- duction use. Some features are missing on Windows (including multi-process mode) and scalability is limited (Even though Tornado is built on asyncio, which supports support some shorthand for waiting on multiple objects by yielding a list or dict. Use tornado.gen.multi to do this in native coroutines. – can support integration with other packages including Twisted blocking_func, args) Parallelism The multi function accepts lists and dicts whose values are Futures, and waits for all of those Futures in parallel: from tornado.gen import multi async def parallel_fetch(url10 码力 | 268 页 | 1.09 MB | 1 年前3
Tornado 6.4 Documentation
officially supported or recommended for pro- duction use. Some features are missing on Windows (including multi-process mode) and scalability is limited (Even though Tornado is built on asyncio, which supports support some shorthand for waiting on multiple objects by yielding a list or dict. Use tornado.gen.multi to do this in native coroutines. – can support integration with other packages including Twisted blocking_func, args) Parallelism The multi function accepts lists and dicts whose values are Futures, and waits for all of those Futures in parallel: from tornado.gen import multi async def parallel_fetch(url10 码力 | 268 页 | 1.09 MB | 1 年前3
Tornado 6.3 Documentation
officially supported or recommended for pro- duction use. Some features are missing on Windows (including multi-process mode) and scalability is limited (Even though Tornado is built on asyncio, which supports support some shorthand for waiting on multiple objects by yielding a list or dict. Use tornado.gen.multi to do this in native coroutines. – can support integration with other packages including Twisted blocking_func, args) Parallelism The multi function accepts lists and dicts whose values are Futures, and waits for all of those Futures in parallel: from tornado.gen import multi async def parallel_fetch(url10 码力 | 264 页 | 1.06 MB | 1 年前3
共 20 条
- 1
- 2













