Updated: May 25, 2023

Spring Boot vs. Quarkus: Which Java Framework to Choose?

Alexey Krivov.

Alexey Krivov

ex Software Engineer

Software Development
Spring Boot vs. Quarkus: Which Java Framework to Choose?

If you have fallen for the hype that Java is going to retire, don’t jump to conclusions right away. Sure, some modern languages may be superior to Java in many ways, even in its primary uses. But Java is initially a great solution, rightly deserving of its colossal popularity and respect from professionals around the world. This is why Java development is actively ongoing, improving and extending its capabilities while third-party teams offer their own frameworks.

Today we discuss two frameworks, Spring Boot and Quarkus, and more specifically, who needs them and why. Let's compare Spring Boot vs Quarkus in terms of feature set, performance metrics, average development cost, market popularity, and other important aspects. This article will help you decide whether Spring Boot or Quarkus is better for your applications and more worth learning.

What is Spring Boot

Let's pay tribute to the oldies. Spring Boot is the open-source Java-based framework supporting Java, Kotlin and Groovy, and JIT compilation, making it much easier to create, configure and run microservices enterprise web applications. 

Its first version was released back in 2002 with the Apache 2.0 license. Since then, it has managed to develop a huge number of extensions, which simplify, improve or extend standard solutions for designing, writing, and maintaining enterprise-level applications. 

Spring Boot features 

Spring Boot is a part of the Spring Framework that allows you to use all the features of the Spring Framework, makes it easier to deploy and configure Spring applications, reduces the amount of code, and increases the speed of going to production. This is possible due to the automatic configuration of the application built on Java Annotations.

Here are some of the features of the Spring Framework you can use in your Spring Boot application:

As you might have noticed, the Spring Boot team hasn't lost a minute during these 20 years judging even by the core set of modules. That's why many universal solutions use this framework. However, since we are comparing it with Quarkus, we are more interested now in its functionality related to containerization and microservices handling. Let's see what this newer solution has to offer for this.

What is Quarkus

Quarkus is an open-source Java framework that supports Java, Kotlin, and Scala and provides AOT compilation. It was created to simplify the development and deployment of Java applications in containers like Docker and Kubernetes, as well as to create microservice Java applications with minimal consumption of resources.

Quarkus is very young, since it was founded in 2019. But it is actively developing with the same Apache 2.0 license and is very much to the liking of many because it lives up to its purposes very well. It is easy to use and significantly less demanding on the hardware resources to run applications.

Quarkus features

The initial focus on working with containers, especially Kubernetes, is valued by many developers and companies. Also, Quarkus doesn't initially aim to develop its own framework for everything, as Spring did. Instead, they actively work to maximize integrations and effectively support other already reputable frameworks and services.

It's important to understand that Quarkus is still just at the beginning of its journey, but it's already making great progress and, most importantly, meeting expectations. Now, having learned about the main technical aspects, let's look at the numbers.

Comparing Quarkus and Spring Boot

From the start, comparing these frameworks may not be entirely relevant, but it is necessary. On the one hand, they are in completely different weight categories. You could say Spring has earned the title of an alternative Java standard, redefining all standards up to JavaBeans. It has its own solution for all cases, which are incredibly good and work great together. Quarkus, on the other hand, is just getting started. But using reactive programming, AOT compilation, and the container-first approach has already shown amazing results, which is why it sparked discussions around itself as the heir to the throne.

One should not replace the other, at least not in the short term. Those are different approaches to solving issues; each has earned its place. Obviously, if you see something critical to your business in the list of main technical features offered, you already roughly know your choice.

But take your time. In addition to the theory, you need to look at the practical aspects of each solution, which are best expressed in numbers. 

Spring Boot vs. Quarkus performance

Generally speaking, we can immediately declare a winner when talking about performance and memory consumption. Still, everything is not quite clear, depending on whether we are comparing Spring Boot and Quarkus using JVM or Native.

METRICS SPRING BOOT JVM QUAKUS JVM SPRING BOOT NATIVE QUARKUS NATIVE
Startup time (sec) 1.865 1.274 0.129 0.110
Build artifact time (sec) 1.759 5.243 113 91
Artifact size (MB) 30.0 31.8 94.7 80.5
Loaded classes 8861 8496 21615 16040
CPU usage max (%) 100 100 100 100
CPU usage average (%) 82 73 94 92
Heap size startup (MB) 1048.57 1056.96 - -
Used heap startup (MB) 83 62 12 58
Used heap max (MB) 780 782 217 529
Used heap average (MB) 675 534 115 379
RSS memory startup (MB) 494.04 216.1 90.91 71.92
Max threads 77 47 73 42
Requests per second 7887.29 9373.38 5865.02 4932.04

According to the test data, Quarkus is often better than Spring Boot, not only in the case of Native, where it should be better because it was initially designed for this approach, but even when using JVM, except for a couple of points. 

As we said, everything is not as clear-cut as we would like, but we can catch the trend. Quarkus consumes fewer resources for running an application in almost every case when we talk about Native and sometimes in JVM. Spring Boot may perform better after application startup, especially with the JVM. It is also worth noting that support for native code was originally built into the Quarkus architecture, while Spring is in an experimental version. This fully explains the separation of Quarkus when working as a native application.

Spring Boot vs. Quarkus popularity

Of course, Spring Boot remains much more popular than Quarkus. We can say that most developers and companies mean Spring Boot when they develop enterprise Java applications. And likely, this will continue for a long time in the enterprise environment, where you need stable, tested, and complex solutions, like Spring Boot. 

However, Quarkus is rapidly gaining popularity, especially in cases with Kubernetes, providing much lower resource consumption. All this is also important for businesses because resource consumption has to be paid for. Naturally,owners want to reduce it, which Quarkus does very well. Also, many developers and companies are starting to see it as the future because it makes development much easier and stays based on industry standards, unlike Spring Boot, which has redesigned all the standards. 

We can conclude here that Spring Boot holds well-deserved popularity as a complete, universal solution for any task right out of the box and to use this in very large and busy enterprise environments. Quarkus is actively gaining it in business solutions, where a standalone solution, resource reduction, and excellent container handling are important. Quarkus performs well because it was originally designed as a native solution and special attention to Doker and Kubernetes.

Spring Boot vs. Quarkus development cost

Which one would be cheaper to develop with? This is quite a complicated question because you have to consider many factors, from the cost of developers to the complexity and duration of the project. Let's first try to figure out the cost of developers.

In the case of Spring Boot, it's not hard to find information. According to GlassDoor, the average salary of a Spring Boot developer in the United States is about $92,000 per year. Of course, this figure can vary greatly depending on experience and location, which may be helpful to you.

Quarkus developer costs, on the other hand, aren't that obvious since there aren't that many of them, and there's not much data on resources like GlassDoor. But for most jobs, the compensation starts at $100,000. And finding those who have already thoroughly learned and switched their specialization to Quarkus can be a challenge for your HR department.

Now let's look at the speed of development. Here everything is not so unambiguous. Spring Boot offers many quality out-of-the-box solutions, which noticeably speed up the development of microservices applications. However, Quarkus also greatly speeds up development due to features like Live coding, Dev UI, and very convenient and simplified handling of Kubernetes containers. Thus, the development speed of large and complex enterprise applications will be much faster on Spring Boot and much cheaper. But development on Quarkus may be cheaper in more specialized cases, especially with Kubernetes containers.

Moreover, the speed of development is strongly influenced by good documentation. Here it is worth noting that Spring Boot documentation is very rich, but surfing the forums, you may find concerns that it is not always up-to-date and may not keep up with the actual functions of the product.

In addition to the documentation, there's also a diverse Spring Boot community, which gives an answer to any question. Quarkus, on the other hand, of course, cannot yet boast such a huge community, although it is already quite large and very responsive. 

All this, to some extent, affects the speed of development and, therefore, the final cost of development. And with a lot of nuances, we can say that development on Spring Boot is probably going to be cheaper in most cases.

Spring Boot vs. Quarkus pros and cons

Let's highlight each framework's main pros and cons to simplify the choice for those who do not want to get too deep into the numbers. 

Spring Boot pros

Spring Boot cons

Quarkus pros

Quarkus cons

Of course, you can use any of these frameworks for most tasks, but each solution has advantages and disadvantages. So you need to decide which ones are important for your project. You can also look at other frameworks whose key advantages may suit you better than both of the previous solutions.

Spring Boot and Quarkus alternatives

If you are not satisfied with Spring Boot or Quarkus, you may consider other alternatives such as: 


💡 If you are unsure what to choose, you can tell us about your project during a free consultation. Our Delivery Managers will carefully consider your case and offer the most suitable and profitable solution for the launch and growth of your business.


Micronaut

Micronaut is a Java-based framework that supports languages like Java, Kotlin, Groovy, and AOT compilation. Its main goal is to provide better performance and less resource consumption.  

Micronaut is still young, founded in 2018 and published under the Apache 2.0 license, making its community active but not yet very large.

Knative

Knative is an open-source PaaS for enterprise-level serverless application development and automated deployment and scaling in Kubernetes.

Dropwizard

Dropwizard is a Java-based framework for fast bootstrapping of Java REST services. It provides several other frameworks and support for Java libraries that will help make creating, running, and deploying your application much easier.

One of the well-known sponsors is JetBrains, which makes excellent IDEs for a variety of developers and also fully supports this framework on its platform.

Summary

In conclusion, both frameworks are awesome. No matter what you choose, you will be able to achieve your goals with the best quality. The only difference is how comprehensive or specialized your solution is and whether you prioritize the application's speed or development itself. And, of course, what key technical solutions are crucial to your project.