Getting started as a programmer with your first Java Spring/Quarkus application can always be a daunting experience. Luckily, there are a lot of tools plugins, and libraries that can make our lives a bit easier.

44 Tools, Plugins and Libraries to Get Started with Your First Java Spring/Quarkus App - Digma spring quar removebg preview 1

In this article, I’d like to touch upon some of the tools, plugins, and libraries for Java Spring/Quarkus development and briefly explain what they are.

Tools

The proper tools can aid you in learning specific standards/setting up your first projects/automating tasks/etc.

SDKMan!

sdkman.io

When you want to start developing your Java applications, you’ll need to have a Java Development Kit (JDK) installed. While you can download any openJDK such as Adoptium, I recommend using SDKMan! as it easily allows you to have multiple versions installed next to each other (which is nice when one wants to experiment) and also allows you to install other tools.

44 Tools, Plugins and Libraries to Get Started with Your First Java Spring/Quarkus App - EW5CQGDxs7mc f XvOeO5gmvdmOuP

JetBrains Toolbox & IntelliJ CE

https://www.jetbrains.com/toolbox-app/

A good Integrated Development Environment (IDE) can immediately set you on the right track. My preferred free, feature-rich one is IntelliJ Community Edition. It offers a lot of advice and quality-of-life functionality when setting up your application.

The toolbox allows you to easily keep your IDEs up to date, and to have multiple versions installed. (I like using the early access builds to try out the new features)

logic) like Spring Boot to your application or set up how you want to build your code.

While you can certainly do a lot through your IDE, or using the Java compiler, sooner or later some tooling comes in handy. Currently, Maven and Gradle are the 2 most popular build tools.

Git

git-scm.com

Once you’ve started writing your source code, it quickly becomes interesting to start doing some form of version control. This way it becomes easy to manage your code (and potentially revert to an earlier version of it in case you do run into an issue), and it facilitates collaboration with other developers.

You can use Git locally, but it’s quite useful to register a free account on GitHub or GitLab so you can push your code to a central place, from which you (or others) can easily fetch the code.

A good IDE will easily allow you to perform most versioning-related actions, but some may prefer using the command line.

GitHub Desktop/Sourcetree/GitKraken/TortoiseGit

tortoisegit.org

When you’re just getting started with source control (which nowadays you’ll most likely do using Git) a nice user interface will make this a much smoother experience. For example: if you want to see what’s happening with your branches, want to see what you still need to commit, perform merges in case both your local and remote code has changed, …

I do recommend learning the commands further down the line, but there’s certainly nothing wrong with using these tools!

44 Tools, Plugins and Libraries to Get Started with Your First Java Spring/Quarkus App - MLkNtSWTjXSvcZaghGe3waKouagxxLcqo d veTKZ2 7XU uejKNo Il7h jI dHz9wXg llgh2 ebWRAOFru2GzOqs8PpEMRFQBaTe869nLkZcN3TJKK6EiwBg rwegjTH6pKzkMSnWjKp30tSOfMw

Spring Initializr / Code Quarkus app

code.quarkus.io

Setting up your build can be a daunting challenge, luckily both Spring and Quarkus offer a setup site. These allow you to select your preferred build tool, which functionality you want, and pass in your application’s artefact ID and group to quickly bootstrap your application.

44 Tools, Plugins and Libraries to Get Started with Your First Java Spring/Quarkus App - ItLk0ZKDKFB20 wRQmL5TDrsLEL7hgbFc6GWU2nT0cHCRIdNQptQ6cbsdQL7tLLNksV EcfN ivoBWwlP 5bE1SOKjtL nRBs RKA Fw7jM8BGC9zsRK8q3Wv dgqU9yWz3riwJAUMH7M8YI5nsePc
44 Tools, Plugins and Libraries to Get Started with Your First Java Spring/Quarkus App - dEw9WqdQi0njXvyFZCDh7TBjTBhvODIbGovYyb81Wy 8

Spring Boot CLI / Quarkus CLI

In case, you’re more at him in your terminal or want to script your generation both Spring and Quarkus also offer a CLI tool.

quarkus.io/guides/cli-tooling

JBang

jbang.dev

Sometimes you want to quickly prototype something or run a simple Java file. While JShell and the new multifile launch (Java 22) do help quite a bit, you will still run into challenges when you need to add dependencies.

That’s where a tool like JBang comes in handy (which will even take care of downloading Java for you if it’s not installed!).

44 Tools, Plugins and Libraries to Get Started with Your First Java Spring/Quarkus App - v5NqBKNH yWU2piAyDbpFv YwZCp4i86flvDyqn2vk6aCJh0YTSAT4M1FdP ScMitFWl6D36h JeyZm3yOZkjH1 MJhfaZ65vX1QXup9RynLttuzZ

JHipster

jhipster.tech

In case you’re interested in quickly generating a Spring boot & Angular/React/Vue project, JHipster has you covered! It’s a free and open-source application generator that will have you up and running in no time!

Their documentation is magnificent, and Matt Raible wrote a useful mini-book

Just answer a few questions and your basic project will be generated for you!

44 Tools, Plugins and Libraries to Get Started with Your First Java Spring/Quarkus App - aJUyRK ibLwgcvG35yBrQX3NNZt6B6xX4p zSV5vIJS7V4Gg7MmF

Docker

docker.com

Docker allows us to manage (start/stop/download/…) so-called containers which are lightweight, portable & self-contained units that package application(s) and everything needed to run them. For example, rather than the “classical” installation of say MySQL, we could instead of the official MySQL docker image. We can even create custom images with their own configuration.

Using this approach means we have a much more repeatable approach, that can easily be shared with others and can easily be added/removed. Rather than the more cumbersome approach of (un)installing.

Testcontainers Desktop

testcontainers.com/desktop/

Over the past few years, Testcontainers (a library that simplifies integration testing by providing easy-to-use, lightweight containers for databases, message queues, …) have become a lot more popular. 

This free-to-use application simplifies the management thereof. It gives us increased insights into what’s happening in our test sessions, integrates with their cloud offering, enable reusable containers, …

44 Tools, Plugins and Libraries to Get Started with Your First Java Spring/Quarkus App - sNB 49dxbxoa jffwtH1setcAN4yU8m Apox5h1uGeaavEn HnN3PL2mU mhWrcPN5RDNiKRGh6yzcmU2S25 VzIisIBqxGJWlXi3GuvxjtAv6NMgzCBHVH8cTSY SEX2 CC mFeb8W7nBnWfQlUmn4

OpenRewrite/Moderne

https://github.com/OIdriss/springbootdc/blob/main/main/java/org/example/webshop2/user/UserDTO.java

I’ll admit, this one is a bit of an odd one out, especially for a more beginner-oriented article.

OpenRewrite, and Moderne(the paid, but free for open-source projects platform) enable mass-scale refactorings of applications.

Now when you’re writing your first projects this isn’t too relevant yet, but as some of your sample projects age, it might be interesting to have them automatically (to the degree possible) upgraded to the latest version. 

This might also be quite interesting if you’ve received some older sample code, and want to see what it would look like nowadays. For example, to refactor some Java 8 code, to make use of some best practices and new features from Java 21 you merely need to do:

mvn -U org.openrewrite.maven:rewrite-maven-plugin:run -Drewrite.recipeArtifactCoordinates=org.openrewrite.recipe:rewrite-migrate-java:RELEASE -Drewrite.activeRecipes=org.openrewrite.java.migrate.UpgradeToJava21

Gatling

gatling.io

Gatling’s a great application for performance, and load testing of your application. It can be run both locally, and in the cloud. Load testing itself is quite important, as you do want to ascertain how well your application behaves when under load, and if there are any concurrency issues.

If you’re interested in more details, you can read my previous article Load Testing: Shoot Your Application With Gatling.

Java Microbenchmark Harness (JMH)

github.com/openjdk/jmh

At times you might have some performance concerns for a specific functionality, and that’s where the JMH comes in handy! 

It allows us to measure:

  • average time per operation
  • sample time for each operation
  • operations per unit of time
  • the time for a single operation

After all: “Measure twice, cut once.”. It’s always best to get a good baseline and idea of where the perceived bottleneck is.

VisualVM

visualvm.github.io

When we want to monitor/troubleshoot/profile applications running on the Java Virtual Machine (JVM) VisualVM comes in handy. It offers us a visual representation of the CPU, memory, thread and class usage. Easily allowing us to gather better insights.

44 Tools, Plugins and Libraries to Get Started with Your First Java Spring/Quarkus App - CzJFvVAvNxvqjwUZ8LVDWkOhy0j7r6zmIfiNWyVMxE9VQdDHUoP53Q0o4o45wZ8fQnl IOgm892zj67 FXp9VMRNZo405qjeC2HmwoGB8BPtJNEdD6C8qVKRFiv

Java Flight Recorder (JFR)

https://docs.oracle.com/en/java/java-components/jdk-mission-control/8/user-guide/using-jdk-flight-recorder.html#GUID-D38849B6-61C7-4ED6-A395-EA4BC32A9FD6

JFR is a profiling/event collection framework that’s built into the JDK that allows us to gather so-called events (blocked thread, the health of the system, usage of deprecated methods, custom events, …)  during a time-fixed (also known as a profiling recording), or as a continuous recording.

44 Tools, Plugins and Libraries to Get Started with Your First Java Spring/Quarkus App - oCXVmT0yZV yZYVHAekAwzToq3CcrgmcsMNzMn4aRckj8Gd0pinOubMJGPwjGDDXvjmjFyZWiGGIeEXKVFnTBeS OWQ

Digma Continuous Feedback (CF)

https://plugins.jetbrains.com/plugin/19470-digma-continuous-feedback

When we get started with writing our first application (Hello World!), we’re already happy that it runs as expected. But as our applications become more complex, the importance of knowing what’s happening behind the scenes, and gathering insights into what’s potentially slowing us down becomes increasingly important. 

This is where the OpenTelemetry standard comes into play when we want to go beyond logging.
OpenTelemetry is an open source, Cloud Native Computing Foundation incubating project that collects APIs, SDKs, and tools to help us observe what’s going on in our application, and to collect/export this data so that we can act upon it.

Digma itself is a tool that helps developers interpret, and act upon this data all from the convenience of our IDE to reduce the abstraction layer.

It also provides some automated insights such as suspected N+1.

The Digma blog also has a nice post about improving your code design using observability.

44 Tools, Plugins and Libraries to Get Started with Your First Java Spring/Quarkus App -

IDE Plugins

Your favourite IDE, be it Visual Studio Code, VIM, or IntelliJ, … likely has a lot of plugins that can smoothen out your workflow.

Here are a couple of plugins that I use daily:

  • rainbow brackets: it makes it a lot clearer where your brackets start/end
  • .env files support: simplifies environment variable management for run/debug configurations, with syntax highlighting
  • translation: integrates a lot of translation engines making it easier to localize your comments/properties.
  • String manipulation: as the name implies, it offers a lot of text manipulation options such as case alterations
  • JPA Buddy: this plugin lowers the barrier when working with JPA, Lombok, MapStruct, …
  • Key Promoter X: to speed up your development speed it’s useful to learn the shortcuts for frequent actions, this is a tool that shows you the missed shortcut & how often you’ve missed it
  • Digma: the IntelliJ plugin for the tool mentioned earlier

For more interesting plugins, I can recommend the blog post by Lee Sheinberg: 25 Best IntelliJ IDEA Plugins for Developers in 2023

Libraries

There are a lot of Micronaut/Quarkus/Spring/… specific libraries that are worth diving into, and they’re certainly worth an article of their own. But when you’re starting, I generally recommend following their documentation which generally introduces you to the specific ones (such as Spring Security, Panache, …) 

Thus let’s take a look at some of the more useful, framework-agnostic ones.

  • Apache POI: in case you need to interact with files based on OOXML such as Word files
  • Apache PDFBox: create & change PDF files, or extract their content
  • ArchUnit: a way to verify, and safeguard your code’s architecture (this is a more detailed article)
  • AssertJ: one of the most popular libraries for writing fluent assertions
  • Awaitility: a magnificent library for when you want to test asynchronous operations
  • caffeine/ehcache: high-performance caching libraries
  • DataFaker: a library that helps you generate good fake data for your tests, which otherwise can be a laborious process
  • iText: a very useful, expansive library to create PDFs (do make sure to use the correct version!)
  • Jackson: a high-performance JSON processor
  • JaCoCo: free Java Code Coverage library. Helpful to keep track of how well you’re doing testing-wise
  • JobRunr: a distributed job scheduler
  • JUnit: one of the most popular unit testing frameworks
  • Liquibase/Flyway: database migration management library. It helps you incrementally update your database model
  • MapStruct: a bean code mapping generator. These libraries have their (dis)advantages, but this is one of the most commonly used ones
  • Playwright: end-to-end testing library for your applications
  • ShedLock: when you need distributed schedule locking
  • Testcontainers: lightweight manner to manage containers. For example use a real DB container, rather than H2!
  • Togglz: manage feature flags for your application in a convenient manner
  • WireMock: a tool for building mock APIs, very useful when you’re dependent on unstable APIs during your development process

Editor’s note: 44 Tools, plugins and libraries for Java Spring/Quarkus development

This is by no means an exhaustive list of tools, plugins, and libraries to get started with your first Java Spring/Quarkus app, but hopefully, these items will help you get started. Please feel free to reach out if I missed something essential, and enjoy the journey!

This article was contributed to the Digma blog by Simon Verhoeven, a Senior Software Engineer and Java Consultant with a particular focus on Cloud quality and Maintainability.

Install Digma: Here

Spread the news:

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *