Skip to content

The goal of this project is to compare some Java Microservice Frameworks like: Quarkus, Micronaut and Spring Boot. For it, we will implement applications using those frameworks, build their JVM and Native Docker images and measure start-up times, memory footprint, etc.

Notifications You must be signed in to change notification settings

ivangfr/graalvm-quarkus-micronaut-springboot

Repository files navigation

graalvm-quarkus-micronaut-springboot

The goal of this project is to compare some Java Microservices Frameworks like: Quarkus, Micronaut and Spring Boot. For it, we will implement applications using those frameworks, build their JVM and Native Docker images and measure start-up times, memory footprint, etc.

Proof-of-Concepts & Articles

On ivangfr.github.io, I have compiled my Proof-of-Concepts (PoCs) and articles. You can easily search for the technology you are interested in by using the filter. Who knows, perhaps I have already implemented a PoC or written an article about what you are looking for.

Additional Readings

Categories

Latest Framework Version Used

Framework Version
Quarkus 3.21.0
Micronaut 4.7.6
Spring Boot 3.4.4

Prerequisites

Docker Images

The application’s JVM and Native Docker images can be found in this Docker Hub link.

Bash scripts

We've implemented three bash scripts that collect data used in the frameworks comparison.

  • collect-jvm-jar-docker-size-times.sh

    It packages JAR files and builds Docker images for JVM applications, collecting data such as JAR packaging time, JAR size, Docker image build time, and Docker image size.

  • collect-native-jar-docker-size-times.sh

    It packages JAR files and builds Docker images for native applications, collecting data such as JAR packaging time, JAR size, Docker image build time, and Docker image size.

  • collect-ab-times-memory-usage.sh

    It starts the container for JVM and native applications, collecting data such as startup time, initial memory usage, time taken to run A/B tests for the first time and (after a warm-up period) for the second time, final memory usage, and shutdown time.

  • remove-jvm-docker-images.sh

    It removes the Docker image of JVM applications.

  • remove-native-docker-images.sh

    It removes the Docker image of Native applications.

AB Tests

                     Application | ab Test                                                                                     |
-------------------------------- + ------------------------------------------------------------------------------------------- |
          quarkus-simple-api-jvm | ab -c 2 -n 6000 'http://localhost:9080/api/greeting?name=Ivan'                              |
        micronaut-simple-api-jvm | ab -c 2 -n 6000 'http://localhost:9082/api/greeting?name=Ivan'                              |
       springboot-simple-api-jvm | ab -c 2 -n 6000 'http://localhost:9084/api/greeting?name=Ivan'                              |
       quarkus-simple-api-native | ab -c 2 -n 6000 'http://localhost:9081/api/greeting?name=Ivan'                              |
     micronaut-simple-api-native | ab -c 2 -n 6000 'http://localhost:9083/api/greeting?name=Ivan'                              |
    springboot-simple-api-native | ab -c 2 -n 6000 'http://localhost:9085/api/greeting?name=Ivan'                              |
................................ + ........................................................................................... |
           quarkus-jpa-mysql-jvm | ab -p test-book.json -T 'application/json' -c 2 -n 4000 http://localhost:9086/api/books     |
         micronaut-jpa-mysql-jvm | ab -p test-book.json -T 'application/json' -c 2 -n 4000 http://localhost:9088/api/books     |
        springboot-jpa-mysql-jvm | ab -p test-book.json -T 'application/json' -c 2 -n 4000 http://localhost:9090/api/books     |
        quarkus-jpa-mysql-native | ab -p test-book.json -T 'application/json' -c 2 -n 4000 http://localhost:9087/api/books     |
      micronaut-jpa-mysql-native | ab -p test-book.json -T 'application/json' -c 2 -n 4000 http://localhost:9089/api/books     |
     springboot-jpa-mysql-native | ab -p test-book.json -T 'application/json' -c 2 -n 4000 http://localhost:9091/api/books     |
................................ + ........................................................................................... |
      quarkus-kafka-producer-jvm | ab -p test-news.json -T 'application/json' -c 2 -n 6000 http://localhost:9100/api/news      |
    micronaut-kafka-producer-jvm | ab -p test-news.json -T 'application/json' -c 2 -n 6000 http://localhost:9102/api/news      |
   springboot-kafka-producer-jvm | ab -p test-news.json -T 'application/json' -c 2 -n 6000 http://localhost:9104/api/news      |
   quarkus-kafka-producer-native | ab -p test-news.json -T 'application/json' -c 2 -n 6000 http://localhost:9101/api/news      |
 micronaut-kafka-producer-native | ab -p test-news.json -T 'application/json' -c 2 -n 6000 http://localhost:9103/api/news      |
springboot-kafka-producer-native | ab -p test-news.json -T 'application/json' -c 2 -n 6000 http://localhost:9105/api/news      |
................................ + ........................................................................................... |
       quarkus-elasticsearch-jvm | ab -p test-movies.json -T 'application/json' -c 2 -n 4000 http://localhost:9112/api/movies  |
     micronaut-elasticsearch-jvm | ab -p test-movies.json -T 'application/json' -c 2 -n 4000 http://localhost:9114/api/movies  |
    springboot-elasticsearch-jvm | ab -p test-movies.json -T 'application/json' -c 2 -n 4000 http://localhost:9116/api/movies  |
    quarkus-elasticsearch-native | ab -p test-movies.json -T 'application/json' -c 2 -n 4000 http://localhost:9113/api/movies  |
  micronaut-elasticsearch-native | ab -p test-movies.json -T 'application/json' -c 2 -n 4000 http://localhost:9115/api/movies  |
 springboot-elasticsearch-native | ab -p test-movies.json -T 'application/json' -c 2 -n 4000 http://localhost:9117/api/movies  |

About

The goal of this project is to compare some Java Microservice Frameworks like: Quarkus, Micronaut and Spring Boot. For it, we will implement applications using those frameworks, build their JVM and Native Docker images and measure start-up times, memory footprint, etc.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published