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

科技回声

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

GitHubTwitter

首页

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

资源链接

HackerNews API原版 HackerNewsNext.js

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

Gnet is the fastest networking framework in Go

112 点作者 mfru大约 1 年前

8 条评论

tutfbhuf大约 1 年前
People in the Go community often respond with "use net/http for building web apps", the standard library is good enough and has better support in the long run. This is good advice in most cases. However, if you are using Go for API building and explicitly want to squeeze out every little bit of performance, then there are much faster libraries available than the standard net/http. Gnet is one such example.
评论 #39711499 未加载
Akronymus大约 1 年前
And what are the downsides? Hard to maintain code? Having to deeply integrate the code to get the advertised performance?<p>Also: &quot;Multiple Porotocols&quot;<p>Oh, there it is on the github: &quot;Note that the HTTP implementation of gnet on TechEmpower is half-baked and fine-tuned for benchmark purposes only and far from production-ready.&quot;
评论 #39711095 未加载
评论 #39710047 未加载
weitendorf大约 1 年前
<a href="https:&#x2F;&#x2F;gnet.host&#x2F;docs&#x2F;about&#x2F;overview&#x2F;" rel="nofollow">https:&#x2F;&#x2F;gnet.host&#x2F;docs&#x2F;about&#x2F;overview&#x2F;</a> - This is a very similar threading model to envoy [0] and lmax disruptor [1]. Unfortunately IIUC writing this in Go still prevents the spin-locked acceptor thread from achieving the kind of performance you could get in a non-GC language, unless you chose to disable GC, so I&#x27;d guess Envoy is still faster.<p><a href="https:&#x2F;&#x2F;gnet.host&#x2F;docs&#x2F;quickstart&#x2F;" rel="nofollow">https:&#x2F;&#x2F;gnet.host&#x2F;docs&#x2F;quickstart&#x2F;</a> it&#x27;s nice that you can use this simply though. Envoy is kind of tricky to setup with custom filters, so most of the time it&#x27;s just a standalone binary.<p>[0] <a href="https:&#x2F;&#x2F;blog.envoyproxy.io&#x2F;envoy-threading-model-a8d44b922310" rel="nofollow">https:&#x2F;&#x2F;blog.envoyproxy.io&#x2F;envoy-threading-model-a8d44b92231...</a><p>[1] <a href="https:&#x2F;&#x2F;lmax-exchange.github.io&#x2F;disruptor&#x2F;#_what_is_the_disruptor" rel="nofollow">https:&#x2F;&#x2F;lmax-exchange.github.io&#x2F;disruptor&#x2F;#_what_is_the_disr...</a>
tazu大约 1 年前
Is there an HTTP server library built on top of this? I&#x27;m getting tired of Fiber&#x2F;FastHTTP.
评论 #39709885 未加载
rmac大约 1 年前
the perf is for plaintext? why not encoded?<p>no quic &#x2F; h3 ?<p>love the work and that it&#x27;s open source but let&#x27;s push the envelope!
latchkey大约 1 年前
I built a tcp service using gnet and it was fantastic. I was really impressed with how easy it was to integrate with.
linter大约 1 年前
Lacking documentation. Take a look at Django if you want to learn how to write your documentation.
评论 #39712381 未加载
bsaul大约 1 年前
can you run grpc over it ?
评论 #39711303 未加载