Spring Boot: Local Development Enhancements, Let’s Compose!

Quite often when we are developing an application we need external services such as rabbitMQ, Kafka, etc. When you are developing locally, you are quite likely using a docker-compose file to start these up, and I am certainly (hopefully) not the only one that has forgotten at least once to start these instances up. And maybe you are even already …

Read More »

Well Worth My Time: “OpenJDK Migration for Dummies”

I’ve just read the (free) OpenJDK Migration for Dummies book. It was well worth my time! I first started using Java in 1998, so I’ve got a long history with it and feel very comfortable with the language itself. However, the licensing changes and proliferation of OpenJDK distributions are much more recent, and those aspects can be a bit confusing. …

Read More »

Debugging as a Process of Isolating Assumptions

Debugging is an integral part of any software development process. It’s a systematic hunt for bugs and mistakes that may be hidden in the intricate lines of your code. Much like a hunter and its prey, it requires a precise method and a set of specific tools. Let’s delve deeper into the fascinating process of isolating assumptions to effectively debug …

Read More »

Introduction to the Tower Library

One of the components of my OpenTelemetry demo is a Rust application built with the Axum web framework. In its description, axum mentions: axum doesn’t have its own middleware system but instead uses tower::Service. This means axum gets timeouts, tracing, compression, authorization, and more, for free. It also enables you to share middleware with applications written using hyper or tonic. …

Read More »

Testing and Local Development Made Simpler with Testcontainers Desktop App

Being able to release new features quickly is a must-have capability in today’s competitive world. In order to release your software quickly and often you should have CI/CD infrastructure that can automatically build, test, and release our software with minimal to no human intervention. A comprehensive automated test suite is the key to release your software with confidence. Testcontainers libraries …

Read More »

Generate AI-based Images with Quarkus and OpenAI DALL.E

In this article, we explore how to integrate OpenAI API with Quarkus. We will create a Quarkus application using the new REST Client Reactive to invoke the OpenAI DALL.E API for images generation. OpenAI API Overview Before jumping into the code, let’s explore the OpenAI Create Image API and how it works. Create Image Request The body request is made …

Read More »

Is OpenJDK Just a Drop-In Replacement?

I don’t know anyone who is still using the Oracle JDK. It has been my recommendation for quite a while to just switch to an OpenJDK distribution as they are roughly drop-in replacements for Oracle’s official JDK. I’ve repeated that advice quite frequently but I guess I glossed over a lot of details that might be insignificant for hackers but …

Read More »

Taming the Bias: Unbiased Safepoint-Based Stack Walking

Walking only at safepoints has advantages. The main one is that you aren’t walking the stack in a signal handler but synchronously to the executed program. Therefore you can allocate memory, acquire locks and rematerialize virtual thread / Loom frames. The latter is significant because virtual threads are the new Java feature that cannot support using signal-handler-based APIs like AsyncGetCallTrace. …

Read More »

Thread-Safe Counter in Java: A Comprehensive Guide

In this tutorial, we will explore the concept of thread safety in Java, specifically focusing on a simple counter. We will start by understanding why a basic counter is not safe for multiple threads; then, we will progressively enhance its thread safety using different techniques such as synchronization, locks, Unsafe, VarHandle, and finally, AtomicInteger. We will be referencing the code …

Read More »