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

科技回声

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

GitHubTwitter

首页

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

资源链接

HackerNews API原版 HackerNewsNext.js

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

Ask HN: Micronaut vs. Quarkus

5 点作者 gauravphoenix将近 5 年前
Needless to say, I have Googled but I am seeking first-hand experience of HNers of using one of these framework in production. I played with these frameworks in some toy projects and I personally find Micronaut somewhat easier to use, perhaps, because I find Micronaut has better documentation

2 条评论

StevePerkins将近 5 年前
I evaluated both of these for a &quot;serverless&quot; function, that ended up becoming a traditional Spring Boot microservice instead.<p>However, here are some of my impressions, in no particular order:<p>1. Micronaut comes from the team behind Grails, which is built on top of Spring. It is clearly designed to be as familiar as possible for developers with Spring experience.<p>2. Quarkus comes from the developers behind JBoss (or Wildfly, whatever). It is clearly designed to be as familiar as possible for developers with Java EE experience.<p>3. If you have experience with neither Spring nor Java EE, then the Micronaut documentation will probably be easier to follow. The Quarkus documentation assumes that you already know a lot about CDI and other Java EE standards, and it mostly focuses on how Quarkus differs from those specs. Their documentation SUCKS at presenting the framework to a fresh audience without all that baggage.<p>4. On the other hand, Quarkus actually delivers on the size and resources hype. I was able to follow the docs with no issue, to use a multi-stage Docker build to make a native executable without GraalVM even being installed (I did have some issues with Gradle, they are clearly Maven-first). Startup is near-instant, even if you AREN&#x27;T using GraalVM, and resource use is low.<p>5. I never got as far with Micronaut in building native executables. And while the startup speed and resource use is lower than a Spring app, it isn&#x27;t DRAMATICALLY lower. Quite frankly, I think they&#x27;re in a &quot;mushy middle&quot; position. Not compelling enough to migrate away from Spring... but if you really DO need to go lighter than Spring, then there are better options.<p>It a nutshell, I might use Quarkus if I wanted to use Java to write a serverless function (or other such constrained context). For general microservices, I&#x27;d just continue to use Spring Boot, and wait for their next release or two to steal most of these innovations anyway.
karmakaze将近 5 年前
I&#x27;ve never heard of Quarkus or used Micronaut. I did once survey available smaller&#x2F;newer frameworks and considered Micronaut to be larger than my use cases.<p>Just reading the Quarkus docs now, I see they&#x27;re using Hibernate. That was the one big problem I had working with Spring&#x2F;Boot and I would personally avoid it although I don&#x27;t have recommended replacement. My problem with JPA+Hibernate was that it was being clever (e.g. delaying operations, caching query templates) as well has creating different forms SQL vs JPQL with different limitations and gotchas.<p>You already like Micronaut and its docs. If not using Hibernate I&#x27;d say go for it. When I looked at it, it seemed like a more modern Spring.
评论 #23673320 未加载