<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Asyncio - 标签 - 研发日志 · R&amp;D Log</title><link>https://rd163.visword.com/tags/asyncio/</link><description>Asyncio - 标签 - 研发日志 · R&amp;D Log</description><generator>Hugo -- gohugo.io</generator><language>zh-CN</language><managingEditor>whutluohui@gmail.com (小智晖)</managingEditor><webMaster>whutluohui@gmail.com (小智晖)</webMaster><copyright>本作品采用知识共享署名-非商业性使用 4.0 国际许可协议进行许可。</copyright><lastBuildDate>Sun, 07 Sep 2025 00:00:00 +0800</lastBuildDate><atom:link href="https://rd163.visword.com/tags/asyncio/" rel="self" type="application/rss+xml"/><item><title>Python asyncio 的事件循环机制</title><link>https://rd163.visword.com/posts/python-asyncio-event-loop/</link><pubDate>Sun, 07 Sep 2025 00:00:00 +0800</pubDate><author><name>小智晖</name></author><guid>https://rd163.visword.com/posts/python-asyncio-event-loop/</guid><description><![CDATA[<p>在使用 Python 的 asyncio 库实现异步编程的过程中，协程与事件循环这两个概念可以说有着千丝万缕的联系，常常是形影不离的出现，如胶似漆般的存在。</p>
<h2 id="asyncio-事件循环的理解" class="headerLink">
    <a href="#asyncio-%e4%ba%8b%e4%bb%b6%e5%be%aa%e7%8e%af%e7%9a%84%e7%90%86%e8%a7%a3" class="header-mark"></a>Asyncio 事件循环的理解</h2><ul>
<li><a href="https://fastapi.tiangolo.com/async/" target="_blank" rel="noopener noreferrer">FastAPI 文档中对 async 的介绍</a></li>
<li><a href="https://www.lipijin.com/python-asyncio-eventloop" target="_blank" rel="noopener noreferrer">以定时器为例研究一手 Python asyncio 的协程事件循环调度</a></li>
<li><a href="https://www.cnblogs.com/traditional/p/17357782.html" target="_blank" rel="noopener noreferrer">《asyncio 系列》1. 什么是 asyncio？如何基于单线程实现并发？事件循环又是怎么工作的？</a></li>
<li><a href="https://www.cnblogs.com/traditional/p/17363960.html" target="_blank" rel="noopener noreferrer">《asyncio 系列》2. 详解 asyncio 的协程、任务、future，以及事件循环 </a></li>
<li><a href="https://www.cnblogs.com/traditional/p/17364391.html" target="_blank" rel="noopener noreferrer">《asyncio 系列》3. 详解 Socket（阻塞、非阻塞），以及和 asyncio 的搭配</a></li>
</ul>
<h2 id="事件循环第三方实现" class="headerLink">
    <a href="#%e4%ba%8b%e4%bb%b6%e5%be%aa%e7%8e%af%e7%ac%ac%e4%b8%89%e6%96%b9%e5%ae%9e%e7%8e%b0" class="header-mark"></a>事件循环第三方实现</h2><p>Python 的 EventLoop 是一个抽象类，它定义了事件循环的基本方法，如创建、运行、停止、注册回调函数等等。除了Python 自带的 asyncio 库，还有其他第三方库，它们都实现了 EventLoop 的功能，如：</p>]]></description></item></channel></rss>