TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Pipelines – a guided tour of the new IO API in .NET

286 点作者 benaadams将近 7 年前

6 条评论

nathanaldensr将近 7 年前
As Tychus Findlay might say, &quot;It&#x27;s about damned time.&quot;<p>The Stream API has to be one of the ugliest warts in .NET, <i>and it&#x27;s been around since the beginning.</i> I am <i>so glad</i> Microsoft finally addressed it. Every time I use Stream, I am reminded of how badly the Stream API violates SOLID principles.<p>I like how Microsoft approached the problem from below by introducing new types like Span&lt;T&gt; and Memory&lt;T&gt;, <i>then</i> the Pipes API. It shows that the future of the platform is in good hands.
评论 #17445895 未加载
评论 #17446569 未加载
评论 #17444981 未加载
评论 #17446009 未加载
评论 #17447586 未加载
评论 #17446866 未加载
steveadoo将近 7 年前
I had some trouble using ReadOnlySequence in a library I am writing (mostly because of no documentation). After looking through how Kestrel uses it(they started using Pipelines in ASP.NET Core 2.1) I found their BufferReader[1] class. It made using ReadOnlySequence much easier.<p>Overall, pipelines have been really solid for me so far. Working out how to use it without documentation was a total pain though, hopefully they get that out soon. If anyone is interested I can throw the library up on GitHub if anyone wants some real world examples of using pipelines.<p>[1] <a href="https:&#x2F;&#x2F;github.com&#x2F;aspnet&#x2F;Common&#x2F;blob&#x2F;master&#x2F;shared&#x2F;Microsoft.Extensions.Buffers.Sources&#x2F;BufferReader.cs" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;aspnet&#x2F;Common&#x2F;blob&#x2F;master&#x2F;shared&#x2F;Microsof...</a>
评论 #17445285 未加载
algorithmsRcool将近 7 年前
David Fowler (The architect of this API) is brilliant! The Pipelines API turned out better than I ever expected.
评论 #17445060 未加载
moomin将近 7 年前
This is literally the most documentation on the internet for this API. AFAICT, though, it doesn&#x27;t have compression or encryption stages, yet?
评论 #17445062 未加载
manigandham将近 7 年前
Part 2 here: <a href="https:&#x2F;&#x2F;blog.marcgravell.com&#x2F;2018&#x2F;07&#x2F;pipe-dreams-part-2.html" rel="nofollow">https:&#x2F;&#x2F;blog.marcgravell.com&#x2F;2018&#x2F;07&#x2F;pipe-dreams-part-2.html</a>
tigershark将近 7 年前
Very nice post, I’m eagerly waiting for the next parts.