10 Oct 2025
DZone Java Zone
Infusing AI into Your Java Applications
Artificial intelligence (AI) is becoming increasingly pervasive. As an Enterprise Java developer, you might be wondering what value AI can add to your business applications, what tools Java provides to easily do that, and what skills and knowledge you might need to learn. In this article, we equip you with the basic knowledge and skills that you need to start exploring the capabilities of AI to build intelligent and responsive Enterprise Java applications.
When we talk about AI in this article, we mean getting responses from a large language model (LLM) based on a request that the Java application sends to the LLM. In our article's example, we create a simple chatbot that customers can ask for planetary tourist destination recommendations, and then use to book a spaceship to visit them. We demonstrate using Java frameworks like LangChain4j with Quarkus to efficiently interact with LLMs and create satisfying applications for end-users.
10 Oct 2025 7:00pm GMT
Diving into JNI: My Messy Adventures With C++ in Android
So, I've been deep in the trenches with JNI lately (yeah, that Java Native Interface stuff) while working on a project where we had to plug a C++ AI assistant into our Android app. At first, it felt like stepping into a weird twilight zone - half Java, half C++, and all these random edge cases you never think about until you hit them. I remember staring at the stack trace for what felt like hours, realizing that one tiny missed DeleteLocalRef
was enough to crash the whole app. Thought I'd share what actually tripped me up, what worked, and some ways to make life a little less miserable if you ever have to do this.
What the Hell Is JNI Anyway?
JNI is basically the bridge that lets Java (or Kotlin) talk to C/C++ code and vice versa. On Android, it's the only real way to get heavy lifting done efficiently or access low-level APIs that Java/Kotlin just can't reach. Honestly, the first time I tried to wrap my head around it, I felt like I was learning a new language on top of Java and C++ at the same time.
10 Oct 2025 6:00pm GMT
Introduction to Spring Data Elasticsearch 5.5
It's been a while since my first article dedicated to Spring Data Elasticsearch usage as a NoSQL database was published. A couple of articles with configuration changes or hints followed the first article. Therefore, the main goal of this article is to define a new baseline for the full Elasticsearch setup.
Note: All previous articles are listed at the end.
10 Oct 2025 4:00pm GMT
Building Realistic Test Data in Java: A Hands-On Guide for Developers
There's something that every backend or API developer faces sooner or later: the need for good fake data.
Whether you're testing a new API, populating a database for demos, or simply trying to make your unit tests less "boring", fake data is part of your daily routine. The problem? Most fake data feels… fake. You end up with "John Doe" and "123 Main Street" repeated over and over, which doesn't look great when showing a prototype to your team or client.
10 Oct 2025 12:00pm GMT
09 Oct 2025
DZone Java Zone
Efficiently Reading Large Excel Files (Over 1 Million Rows) Using the Open-Source Sjxlsx Java API
If you are a developer, regardless of the technologies you use, at some point, you will face the challenge of handling large Excel files.
Most commonly, you will see the "out of memory" error when handling these files.
09 Oct 2025 12:00pm GMT
08 Oct 2025
DZone Java Zone
Converting ActiveMQ to Jakarta (Part III: Final)
Advanced Technical Approach
Some Java frameworks have taken on the complexity of supporting both javax and jakarta package namespaces simultaneously. This approach makes sense for frameworks and platform services, such as Jetty and ActiveMQ, where the core development team needs to move the code base forward to support newer JDKs, while also providing a way for application developers to adopt Jakarta EE gradually. This simplifies the support for open-source frameworks, as there are fewer releases to manage, and in the event of a security bug, being able to release one mainline branch vs having to go back and backport across past versions.
However, supporting both javax and jakarta namespaces simultaneously in a single application is complicated and time-consuming. Additionally, it opens additional scenarios that may lead to errors and security gaps for enterprise applications. This limits the ability to set up verification checks and source code scanning to block pre-Jakarta libraries from being used or accidentally pulled in through transitive dependencies. It creates a lot of ambiguity and reduces the effectiveness of DevOps teams in providing pre-approved SDKs to be used by enterprise developers. With the pitfalls outweighing the benefits, enterprise projects should not need to support both javax and jakarta namespaces simultaneously in most scenarios.
08 Oct 2025 4:00pm GMT
26 Sep 2025
DZone Java Zone
Building a Real-Time Data Mesh With Apache Iceberg and Flink
If you've ever tried to scale your organization's data infrastructure beyond a few teams, you know how fast a carefully planned "data lake" can degenerate into an unruly "data swamp." Pipelines are pushing files nonstop, tables sprout like mushrooms after a rainy day, and no one is quite sure who owns which dataset. Meanwhile, your real-time consumers are impatient for fresh data, your batch pipelines crumble on every schema change, and governance is an afterthought at best.
At that point, someone in a meeting inevitably utters the magic word: data mesh. Decentralized data ownership, domain-oriented pipelines, and self-service access all sound perfect on paper. But in practice, it can feel like you're trying to build an interstate highway system while traffic is already barreling down dirt roads at full speed.
26 Sep 2025 12:00pm GMT
24 Sep 2025
DZone Java Zone
Top 7 Mistakes When Testing JavaFX Applications
JavaFX is a versatile tool for creating rich enterprise-grade GUI applications. Testing these applications is an integral part of the development lifecycle. However, Internet sources are very scarce when it comes to defining best practices and guidelines for testing JavaFX apps. Therefore, developers must rely on commercial offerings for JavaFX testing services or write their test suites following trial-and-error approaches.
This article summarises the seven most common mistakes programmers make when testing JavaFX applications and ways to avoid them.
24 Sep 2025 11:00am GMT
22 Sep 2025
DZone Java Zone
Think in Graphs, Not Just Chains: JGraphlet for TaskPipelines
JGraphlet is a tiny, zero-dependency library for building task pipelines in Java. Its power comes not from a long list of features, but from a small set of core design principles that work together in harmony.
At the heart of JGraphlet is simplicity, backed by a Graph. Add Tasks to a pipeline and connect them to create your graph. Each Task
has an input and output. A TaskPipeline
builds and executes a pipeline while managing the I/O for each Task
.
22 Sep 2025 11:00am GMT
19 Sep 2025
DZone Java Zone
Spring Boot WebSocket: Building a Multichannel Chat in Java
As you may have already guessed from the title, the topic for today will be Spring Boot WebSockets. Some time ago, I provided an example of WebSocket chat based on Akka toolkit libraries. However, this chat will have somewhat more features, and a quite different design.
I will skip some parts so as not to duplicate too much content from the previous article. Here you can find a more in-depth intro to WebSockets. Please note that all the code that's used in this article is also available in the GitHub repository.
19 Sep 2025 11:00am GMT
16 Sep 2025
DZone Java Zone
How to Migrate from Java 8 to Java 17+ Using Amazon Q Developer
Replatforming from Java 8 to the newer Java versions has proven to be a huge challenge due to potential compatibility issues and changes in language specifications. The Spring Framework, which provides a programming and configuration model for modern Java applications, has just released its latest major version, Spring Framework 6.2.10, and it requires a baseline of Java 17 or higher. Because of this, migrating from an older version like Java 8 would involve code modifications, which take considerable effort and rigorous testing.
Before diving deep into version upgrades for Java applications, let us first discuss what Amazon Q developer is and how it helps developers with application modernization.
16 Sep 2025 7:00pm GMT
15 Sep 2025
DZone Java Zone
Spring Cloud Gateway With Service Discovery Using HashiCorp Consul
This article will explain some basics of the HashiCorp Consul service and its configurations. It is a service networking solution that provides service registry and discovery capabilities, which integrate seamlessly with Spring Boot. You may have heard of Netflix Eureka; here, Consul works similarly but offers many additional features. Notably, it supports the modern reactive programming paradigm. I will walk you through with the help of some applications.
- Spring Boot
- Spring Cloud Gateway
- Spring Cloud Consul
- Spring Boot Actuator
The architecture includes three main components:
15 Sep 2025 6:00pm GMT
09 Sep 2025
DZone Java Zone
Secure Your Spring Boot Apps Using Keycloak and OIDC
In this blog, we will take a closer look at Spring Security, specifically in combination with Keycloak using OpenID Connect, all supported with examples and unit tests. Enjoy!
Introduction
Many applications are supported by means of authentication and authorization. However, it is also something software developers find difficult to grasp. In this blog, Spring Security is introduced, which is Spring's solution for adding security to your Spring applications. By means of examples and unit tests, you will learn the annotations and Spring classes. The end goal is to set up an application using OpenID Connect in combination with Keycloak. An introduction to OpenID Connect and Keycloak can be found in a previous blog. It is advised to read this blog if you are not yet familiar with the concepts.
09 Sep 2025 2:00pm GMT
02 Sep 2025
DZone Java Zone
Monitoring Java Microservices on EKS Using New Relic APM and Kubernetes Metrics
Amazon EKS makes running containerized applications easier, but it doesn't give you automatic visibility into JVM internals like memory usage or garbage collection. For Java applications, observability requires two levels of integration:
- Cluster-level monitoring for pods, nodes, and deployments
- JVM-level APM instrumentation for heap, GC, threads, latency, etc.
New Relic provides both via Helm for infrastructure metrics, and a lightweight Java agent for full JVM observability.
02 Sep 2025 6:00pm GMT
Prototype for a Java Database Application With REST and Security
Many times, while developing at work, I needed a template for a simple application from which to start adding specific code for the project at hand.
In this article, I will create a simple Java application that connects to a database, exposes a few rest endpoints and secures those endpoints with role based access.
02 Sep 2025 4:00pm GMT
01 Sep 2025
DZone Java Zone
Exploring QtJambi: A Java Wrapper for Qt GUI Development—Challenges and Insights
I recently experimented with QtJambi, a Java wrapper for the well-known Qt C++ library used to build GUIs. Here are some initial thoughts, remarks and observations:
- Building a QtJambi project can be somewhat challenging. It requires installing the Qt framework, configuring system paths to Qt's native libraries, and setting proper JVM options. Although it is possible to bundle native libraries within the wrapper JARs, I haven't tried this yet.
- The overall development approach is clean and straightforward. You create windows or dialogs, add layouts, place widgets (components or controls) into those layouts, configure widgets and then display the window or dialog to the user. This model should feel familiar to anyone with GUI experience.
- Diving deeper, QtJambi can become quite complex, comparable to usual Java Swing development. The API sometimes feels overly abstracted with many layers that could potentially be simplified.
- There is an abundance of overloaded methods and constructors, which can make it difficult to decide which ones to use. For example, the QShortcut class has 34 different constructors. This likely comes from a direct and not fully optimized mapping from the C++ Qt API.
- Like Swing, QtJambi is not thread-safe. All GUI updates must occur on the QtJambi UI thread only. Ignoring this can cause crashes, not just improper UI refresh like in Swing.
- There is no code reuse between Java Swing and QtJambi. Even concepts that appear close and reusable are not shared. QtJambi is essentially a projection of C++ Qt's architecture and design patterns into Java, so learning it from scratch is necessary even for experienced Swing developers.
- Using AI tools to learn QtJambi can be tricky. AI often mixes Java Swing concepts with QtJambi, resulting in code that won't compile. It can also confuse Qt's C++ idioms when translating them directly to Java, which doesn't always fit.
- Despite being a native wrapper, QtJambi has some integration challenges, especially on macOS. For example, handling the application Quit event works differently and only catching window-close events behaves properly out of the box. In contrast, native Java
QuitHandler
support is easier and more reliable there, but it doesn't work with QtJambi. - Mixing Java AWT with QtJambi is problematic. This may leads to odd behaviors or crashes. The
java.awt.Desktop
class also does not function in this context. - If you want a some times challenging Java GUI framework with crashes and quirks, QtJambi fits the bill! It brings a lot of power but also some of complexity and instability compared to standard Java UI options.
- There is a GUI builder that works with Qt, but it is possible to use its designs in QtJambi, generating source code or loading designs at runtime. The only issue: the cost starts from $600 per year for small businesses to >$5,000 per year for larger companies.
Notable Applications Built With QtJambi
Notable applications built with QtJambi are few. One example is the Interactive Brokers desktop trading platform (IBKR Desktop), which uses QtJambi for its user interface.
01 Sep 2025 5:00pm GMT