Readers will learn about Spring Boot and Eclipse Micro Profile, including a comparison of the essential metrics in the same web application and guide code.
In this article, we’re going to compare some essential metrics of web applications using two different Java stacks: Spring Boot and Eclipse Micro Profile. More precisely, we’ll implement the same web application in Spring Boot 3.0.2 and Eclipse Micro Profile 4.2. These releases are the most recent at the time of this writing. Since there are several implementations of Eclipse Micro Profile, we’ll be using one of the most famous: Quarkus. At the time of this writing, the most recent Quarkus release is 2.16.2.
This mention is important regarding Eclipse Micro Profile because, as opposed to Spring Boot, which isn’t based on any specification and, consequently, the question of the implementation doesn’t exist, Eclipse Micro Profile has largely been adopted by many editors who provide different implementations, among which Quarkus, Wildfly, Open Liberty and Payara are from the most evangelical.
In this article, we will implement the same web application using two different technologies, Spring Boot and Quarkus, such that to compare their respective two essential metrics: RSS (Resident Set Size) and TFR (Time to First Request).The Use Case
The use case that we’ve chosen for the web application to be implemented is a quite standard one: the one of a micro-service responsible to manage press releases. A press release is an official statement delivered to members of the news media for the purpose of providing information, creating an official statement, or making a public announcement. In our simplified case, a press release consists in a set of data like a unique name describing its subject, an author, and a publisher.
The micro-service used to manage press releases is very straightforward. As with any micro-service, it exposes a REST API allowing for CRUD press releases. All the required layers, like domain, model, entities, DTOs, mapping, persistence, and service, are present as well. Our point here is not to discuss the micro-services structure and modus operandi but to propose a common use case to be implemented in the two similar technologies, Spring Boot and Quarkus, to be able to compare their respective performances through the mentioned metrics.Resident Set Size (RSS)
RSS is the amount of RAM occupied by a process and consists of the sum of the following JVM spaces:
Heap space
Class metadata
Thread stacks
Compiled code
Garbage collection
RSS is a very accurate metric, and comparing applications based on it is a very reliable way to measure their associated performances and footprints.
Домой
United States
USA — software Spring Boot vs Eclipse Micro Profile: Resident Set Size (RSS) and Time...